#24649 - dovoto - Sun Aug 08, 2004 5:09 pm
Speeking of multiplayer / multiboot...
I was able to get multiboot working with little issue booting up to three slaves. I have only tested one slave on hardware as i only have 2 gba but they all boot on no$.
But I am haveing a bit of trouble with the concepts of multiplayer. I was able to get non interupt driven comms to work with each GBA waiting in a loop till the other was ready once per frame.
Once i switched to interupts though I have been haveing issues. It works flawlessly on no$ and is stable but It locks up on the hardware. My basic flow of events is this:
master multiboots slaves:
slaves init multiplay and enable sio irq with 0xDEAD in the send register.
once per frame master sends 0xDEED to wake up the slaves. THe slaves imediatly disable the interupt and multiplay comms then reinable comms to accept handshake data...they wait for master recieve register to also recieve 0xdead. Once it detects 0xDEAD it goes into its recieve loop to recieve the data from the other gba. All sends from master wait for the read bit (bit 3) to indicate all gba ready. Everytime data is recieved the slave immediatly exit multiplayer mode and process the data before reinabling for the next chunk.
after the master detects slave is ready it sends 0xdead then sends the data.
after completion slave reinables sio interupt and returns.
THe interupt is being called.
THere are no other interupts installed.
Works well on no$
My question is: Are there delays that I should be inserting? I allready insert a hefty one on the master after sending wake up data to give time for the slave to respond.
Any advice would be appreciated. THanks.
-jason
_________________
www.drunkencoders.com
I was able to get multiboot working with little issue booting up to three slaves. I have only tested one slave on hardware as i only have 2 gba but they all boot on no$.
But I am haveing a bit of trouble with the concepts of multiplayer. I was able to get non interupt driven comms to work with each GBA waiting in a loop till the other was ready once per frame.
Once i switched to interupts though I have been haveing issues. It works flawlessly on no$ and is stable but It locks up on the hardware. My basic flow of events is this:
master multiboots slaves:
slaves init multiplay and enable sio irq with 0xDEAD in the send register.
once per frame master sends 0xDEED to wake up the slaves. THe slaves imediatly disable the interupt and multiplay comms then reinable comms to accept handshake data...they wait for master recieve register to also recieve 0xdead. Once it detects 0xDEAD it goes into its recieve loop to recieve the data from the other gba. All sends from master wait for the read bit (bit 3) to indicate all gba ready. Everytime data is recieved the slave immediatly exit multiplayer mode and process the data before reinabling for the next chunk.
after the master detects slave is ready it sends 0xdead then sends the data.
after completion slave reinables sio interupt and returns.
THe interupt is being called.
THere are no other interupts installed.
Works well on no$
My question is: Are there delays that I should be inserting? I allready insert a hefty one on the master after sending wake up data to give time for the slave to respond.
Any advice would be appreciated. THanks.
-jason
_________________
www.drunkencoders.com