gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

Coding > Multiboot code help

#9656 - Vortex - Tue Aug 12, 2003 4:20 pm

Hello,

I am testing some communication/multiboot routines between two GBA units with no success so far. The first example I am trying to run is Jeff Frohwein's multiboot client demo:

http://www.devrs.com/gba/files/mbclient.txt

The example uses BIOS SWI 37 (25h) - MultiBoot to accomplish its goal.

I don't have a flash card, so using a MBV2 cable I upload the demo to GBA unit 1, disconnect the MBV2 cable, link the GBAs with a standard link cable and try to boot the second GBA unit. I tried many different setting, but it doesn't work.

I was able to localize the problem in the following portion of code:

Code:


   // Wait until slave boy is awake
   // and ready to be activated. =P
   do
      {
      DelayCycles(921000); //delay ~18ms

      i = xfer (0x6202);
      }
   while (i != 0x7202);


The slave GBA never returns 0x7202. I also tried (0x7204 and 0x7208 with no success).

My questions are:

1. What exactly is wrong with the example
2. Is it supposed to be ran only from a flash-card
3. Is there any way to execute it with a MBV2
4. Are you aware of any relatively easy way to debug multiboot/comm programs

Any help will be appreciated.

Thanks

#9657 - tepples - Tue Aug 12, 2003 5:36 pm

I have gone MBV2 to GBA to GBA to GBA to GBA with no problems. If you want the source code I used, PM me.

Possible things you should do:
1. Try turning off and on the slave GBA while it's plugged in. Sometimes the serial port needs a reset.
2. Make sure the GBA link cable is connected tightly at both ends.
3. Try writing some simple text code so that you can display connection status info on the master GBA's screen.
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.