#14742 - dist0rted - Mon Jan 12, 2004 5:13 am
I've seen no articles or tutorials that cover programming for the multiplayer link that let's more than one GBA play together. Is there a such a thing? Or is Nintendo only giving this information to licensed developers?
_________________
All knowledge is good; only the way it is put to use is good or evil.
#14744 - yaustar - Mon Jan 12, 2004 5:36 am
there is another topic like this somewhere. There is one tuturial I have seen on the Down to You pages...
http://downtou.cjb.net/
_________________
[Blog] [Portfolio]
#14768 - johnny_north - Mon Jan 12, 2004 6:06 pm
The SGADE tutorials include source for a communications module called so_multiplayer.c and .h and a very brief section about it in the help html. There are no other tutorials or code that I?m aware of. But one thing to note, this code works. All you need to do is modify its communication and timer interrupts to call your own handler functions and replace a couple of macros, but that about it. Be sure to implement a good assert() function in your code, because you won?t be able to test or debug in a emulator (at least currently). Implementing error free way to use the communications in the rest of your code it the hard part.
#14830 - dagamer34 - Tue Jan 13, 2004 2:54 am
Well, there is Jeff's multiboot demo on www.devrs.com/gba.
There is also a small header that shows an example of linking. Its somewhere on the ngine.com forums. There is a header there, but no code for exchanging of data.
I had a topic going in the beginners section, might want to look at it. There is little info though. Multiplayer is kind of tough since no emulator supports it (why, because of those &*%# pirates who use it to play commercial games) and not everyone of us has 2 GBAs available for testing as well as 2 flash carts.
Wish I could help you out. If you end up making any working code straight GCC (not SGADE), be sure to share it.... like give it to me...
I am also working on it at the moment. I once was able to send a ROM over multiboot. Pure luck, I guess.
_________________
Little kids and Playstation 2's don't mix. :(
#14831 - tepples - Tue Jan 13, 2004 2:59 am
If you really want a multiplayer emulator, you have time (or money) to burn, and you have an extremely fast PC, then fork VBA and add multiplayer support. The GPL gives you every right to do so. Whether Forgotten will integrate such a patch into mainline VBA is another question entirely.
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.
#14858 - Miked0801 - Tue Jan 13, 2004 6:17 pm
The commercial version of No$GBA supports multiplayer if you can afford the license :P
#14873 - dagamer34 - Wed Jan 14, 2004 2:55 am
Does anybody have the Multiplayer files from the Down to you website because I can't seem to download them. The tutorial doesn't exist. Its as if the page is only a placeholder for something else but I don't see anything.
_________________
Little kids and Playstation 2's don't mix. :(
#14881 - yaustar - Wed Jan 14, 2004 8:59 am
yes, I do... where do you want them?
_________________
[Blog] [Portfolio]
#14885 - bomberman - Wed Jan 14, 2004 10:26 am
Mike,
this no$gba looks impressive... It even provides what he calls conditional breakpoint, which I call watchpoints (because of my Metrowerks Code Warrior experience) and that no other emulators provide :O( But 5000$ is a bit... well expensive, that's the word !
Is this emulator widely used by professional developers ?
Speaking of Code Warrior (the best IDE ever !), I saw there is a version for GBA development... However it is only for professional as well ! Has any professional on this forum used it already and is it good ? What's its cost ?
#14906 - Miked0801 - Wed Jan 14, 2004 6:27 pm
I've used Codewarrior in the past (when doing some PS1 soo long ago), but not recently. It was as easy to use as VStudio was then. Can't help you much more on that.
I can tell that the current version of No$gba's breakpoint, memory watch features, and exceptions catches are worth the money (for a company). I can't count the number of times I was able to find a bad pointer when it tells me that I'm writing to a ROM address. I also helped me find a run away DMA interrupt the other day with the same exceptions. You want to know if a value in RAM is changing, you put a berakpoint on it and know immediately where the offending code is that is doing the evil write. As of the last version, it also supports some limited source level debugging so you can see where in C source the problem is occuring. To be sure, it's not perfect (it's a real pain to see local stack variables currently) and is still a bit buggy - but I'll take the bugs for what it offers in return. Plus, he's still upgrading the thing on a regular basis so if you do find a bug, he's very likely to fix it. Heck, we even written a app that allows us to Profile with his debugger very nicely :)
Martin should give me a kickback for this post ;)
Mike
#14922 - bomberman - Wed Jan 14, 2004 8:26 pm
Hmmm... I think that Visual today is still not at the level of Code Warrior six years ago :O) Especially watchpoints are far less powerful than Code Warrior ones'. And as you say, when you debug, watchpoints are maybe the most important tool :O) Lucky you to have them !!! Unfortunately, VisualBoyAdvance does not manage them and it's a real pity !
You say that source level debugging is recent ??? That's a really important feature as well. And so is the profiling functionality... Professional developers have unfair advantages to us, amateurs :O)
At least with Eclipse, I have at last one IDE where I can both code and debug in a very nice GUI !
#14952 - dagamer34 - Thu Jan 15, 2004 5:11 am
You think you could send me the ones dealing with linking and multiplayer (I think they are the last 3)?
Thanks a lot!!
_________________
Little kids and Playstation 2's don't mix. :(
#14989 - Miked0801 - Thu Jan 15, 2004 7:45 pm
Quote: |
You think you could send me the ones dealing with linking and multiplayer (I think they are the last 3)?
Thanks a lot!!
|
Huh? What are you asking for?
#15008 - dagamer34 - Fri Jan 16, 2004 1:55 am
When looking at the page with all the tutorials on it, these are the ones I am kindly asking if anyone has:
Tutorial 31 - Linking
Tutorial 33 - Multiboot
Thanks for your help.
_________________
Little kids and Playstation 2's don't mix. :(
#15015 - yaustar - Fri Jan 16, 2004 2:49 am
I though I sent them yesterday via email..if not, give me another shout.
_________________
[Blog] [Portfolio]
#15065 - ScottLininger - Fri Jan 16, 2004 7:58 pm
Hey guys,
After pulling out a fair amount of my hair, I finally got a little demo working that shows how to replicate a MULTIBOOT ROM across a link cable (without a 2nd flash cart), and then exchange structured data between the gameboys.
Once the ROM is replicated, the gameboys call a function called ExchangeStructs() once per game loop. Each player has their own STRUCT that you can change to be anything you like. The function handles the multiplayer transfer, ensuring that everyone has a "current state" view of the game.
http://www.thingker.com/gba/MultiplayerV1.zip
Feel free to use, abuse, and improve the code. :)
Cheers,
Scott
#15102 - dagamer34 - Sat Jan 17, 2004 3:07 am
What I really wanted was the tutorials dealing with the linking. All I have found is examples that are meant for the MB ROM to be sent from whatever is inside EWRAM on GBA # 0.
Also, the sending and receiving of data, that was also what i was after. No docs really cover it much. Now I know why.
_________________
Little kids and Playstation 2's don't mix. :(
#16049 - dagamer34 - Sat Feb 07, 2004 4:42 am
I guess I am the only person working on multiplayer right now.
I have a weird problem. I have been able to send the multiplayer part of the SGADE demo from my flash cart over the link cable and gotten it to execute. And the slave shows that nice screen that says, "Waiting for connection to other GBA...."
The problem is that the master GBA has successfully linked and started a session while the slave is still stuck at that screen. What's wrong? I know i haven't changed the code in there. The thing is that if i send the rom over to the slave from my PC and then start linking, it suddenly decides it wants to work...
Life without a multiplayer emulator..... sucks.
_________________
Little kids and Playstation 2's don't mix. :(
#16063 - ScottLininger - Sat Feb 07, 2004 4:50 pm
dagamer,
Can you post the code that's having the problem? I've never actually seen a working SGADE multiplayer demo, so maybe there is a problem with the code.
Scott
#16070 - Miked0801 - Sat Feb 07, 2004 5:21 pm
Make sure you don't have a bug where the first few packets are lost whilst the system stabilizes - I got burned with that. I told the master to send "Go to next state" the first tic connected and the packet quite often got lost. Also, make sure you have packet integrity. Link cable communications are not very clean. Checksum/CRC are your friends.
#16074 - dagamer34 - Sat Feb 07, 2004 6:11 pm
Well, actually it would just be easier to upload my project somewhere.
I stuck some of my library code in there to see if the SGADE code was the problem but no luck. I will post again, once its removed and uploaded somewhere.
There isn't a problem when i send the mb rom from my pc to the slave so what difference does it make?
And I am not immediately starting the linking session. I wait for both users to press the A button before anything starts.
_________________
Little kids and Playstation 2's don't mix. :(
#16079 - dagamer34 - Sat Feb 07, 2004 7:32 pm
Okay, my project is up.
Here's the link:
www.geocities.com/dagamer34/Multi.zip
You will have to type it in the address bar.
Try working on it. Give me your input. Fix it!! Thanks for helping.
_________________
Little kids and Playstation 2's don't mix. :(
#16096 - dagamer34 - Sun Feb 08, 2004 3:24 am
I have succeeded!!! All by myself!!!!
Woopie!!!!
So you are probably wondering how to get it to work huh?
Well, i could tell you.... i guess i might as well.
Download the source code and add these lines to Multiplayer.cpp
Put this somewhere at the top
#include "gba.h"
And put this right BEFORE the call to start a multiplayer session is called
while ((volatile u16)REG_VCOUNT != 160) {}
then... this
if ( ! SoMultiPlayerStart( SO_MULTI_PLAYER_115200_BPS, 2 ) )
{
// We failed setting it up, so we exit;
return;
}
Woot!!! Woot!!!
Expect a library sometime in the next 2 weeks that doesn't have any SGADE code in it.
You are all welcome.
_________________
Little kids and Playstation 2's don't mix. :(
#16339 - panjun10 - Thu Feb 12, 2004 9:01 pm
dagamer34 wrote: |
When looking at the page with all the tutorials on it, these are the ones I am kindly asking if anyone has:
Tutorial 31 - Linking
Tutorial 33 - Multiboot
Thanks for your help. |
and I need one so ,can you send me a copy plz???
my box is panjun10@163.com
I'm all so writing a litter program with xboo....
than I passed send header but I never pass the crc.....
....
The data send and rev like that
<8FBCFDAF:1EC><C53A4112:1F0><367D470B:1F4><60898D58:1F8><24F81E22:1FC><902C8572:200><60EA588A:204><8935FE62:208><E60E32AA:20C>
<65:210><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:74><65:75><66:75>
<9820:7FCA>
what can I do then .....
#16341 - jenswa - Thu Feb 12, 2004 9:26 pm
[quote="panjun10"] dagamer34 wrote: |
When looking at the page with all the tutorials on it, these are the ones I am kindly asking if anyone has:
Tutorial 31 - Linking
Tutorial 33 - Multiboot
Thanks for your help. |
and I need one so ,can you send me a copy plz???
my box is panjun10@163.com
[quote]
Can i get a copy of those too in my in inbox?
Thank you, oh the mail is: awsnej@hotmail.com
_________________
It seems this wasn't lost after all.
#16343 - dagamer34 - Fri Feb 13, 2004 12:48 am
The tutorials are NOT useful, to me anyway. The only thing they do is send an mb ROM. However, if you would like the code i whipped up, you can PM me for an advanced copy before i let everyone else see it.
Actually, I didn't do much, just solved the multiboot problem (sending a mb rom, then starting a multiplayer session) with the SGADE code.
Give me your e-mail address and I'll send the tutorials to you anyway.
_________________
Little kids and Playstation 2's don't mix. :(
#16359 - panjun10 - Fri Feb 13, 2004 5:39 am
my mail is panjun10@163.com
and then my crc checking is
unsigned long calccrc(unsigned long data,susigned long crc)
{
crc^=data;
for(int i=0;i<=31;i++)
{
if(crc&1)crc^=0x186f6;
crc>>=1;
}
return (crc);
}
is this correct??????
#16373 - dagamer34 - Sat Feb 14, 2004 12:54 am
Wow, everyone suddenly wants my code!!! Should be ready by tomorrow, if not sooner. The problem is that my library code is in there, and I don't feel like releasing my library to the public at the moment(will be ready by next week).
It really isn't my code. I only added 1 line to make it work for multiboot, maybe no one else had the time to figure it out.
Like I said, should be ready by tomorrow if not earlier. I will send to you the code I have now, only the interrupt functions need to be changed.
I will give you the code i use for interrupts also, then.
Jeff
_________________
Little kids and Playstation 2's don't mix. :(