Looking For Snes Source Code...


Squidge

Certified Guru
Joined
Nov 16, 2003
Messages
8,493
Location
UK
Website
Visit site
I wonder if anyone has stumbled across archives of demos, homebrew games etc for the SNES? I've looked on pdroms, but I'd prefer demos and games that include source code if possible.

The reason I ask is because my emu is driving me nuts. It's a big compilation of various source from multiple snes emu's, as well as my own. It currently plays a few demos, but I need to test and debugs things singly rather than trying to do everything at once like a commercial game does.

The smaller the rom the better! (I've got some 32KB ones that are ideal educational material for example).

(and for anyone thinking they will be getting a full speed snes emu in the next couple of weeks, dream on and stop salivating over your keyboard... this thread isn't for you)
 
I think I *SHOULD* have a nice few links on my home PC as I was looking into SNES programming sometime last year, so depends on whether I cleared them from my links or not...

most of the stuff I'm currently coming accross with searches are pretty un-comprehensive... a few little tutorials, sites that haven't had new content since 2001...

I'm sure there must be a few good websites out there somewhere with code and tutorials on SNES programming...

there's a fair few sparse bits of info on the following:

http://www.programmersheaven.com/zone8/cat716/
http://www.programmersheaven.com/zone8/cat715/
http://www.programmersheaven.com/zone8/cat47/

Good luck with it Squidge :)
 
Would this be helpful?
http://fdwr.tripod.com/docs.html
http://www.zophar.net/tech/snes.html

A site with information about how to write programs for the SNES with source code and basic routines:
http://filebox.vt.edu/users/rogrubb3/SNESDev/

SNES roms (Most of these are tiny demos - plasma effects and the like):
http://homepage.ntlworld.com/primrose.smit...omebrewroms.zip

There is some weird crap on this site - which may be pretty useful:
http://snescentral.edgeemu.com/snesrpg/

SNESdev starter kit (contains example programs and random crap):
http://nesdev.parodius.com/SNES-starterkit.zip

That is all I could find.
 
Thanks folks :)

Tried the code earlier on today on a 2x and was getting 40 fps (100% C code). Implemented yoyo's asm cpu core, and now are getting 70 fps.

It should be noted however that this emu currently supports no extra chips (No DSP, no SDD1, No suoer-fx, etc), no sound (yet), and only one graphical layer.
 
Thats actually pretty good for a pre-release. Have you gotten any games to play or just demos right now?
 
haha well done me I just realised how many homebrew demo roms I actually gave you. And some of them do really weird things it looks like.

Anyway, goodluck. 70fps is huge, that is insane - what clockspeed was that at?
I know the final speed will be a fraction of this though (I dunno how much lower: 1/2, 1/3, 1/4, 1/10! or more likely 20fps with sound off 5fps with sound on that is what it is normally like hehe), do you think you will be able to create a faster sound core as that has always been what slowed everything down.
 
Thanks folks :)

Tried the code earlier on today on a 2x and was getting 40 fps (100% C code). Implemented yoyo's asm cpu core, and now are getting 70 fps.

It should be noted however that this emu currently supports no extra chips (No DSP, no SDD1, No suoer-fx, etc), no sound (yet), and only one graphical layer.

How fast is the 65816? 2.5Mhz or 3Mhz?
What about Mode7 effects, Transparency?
Is the PPC doing anything?

Looks too good to be true.

Also take a look:
http://filebox.vt.edu/users/rogrubb3/SNESDev/
 
Last edited by a moderator:
Talk to Kojote. Maybe he can give you the contact information of the people that have content on his site.
 
It's just demos, although I'm going to try and get donkey kong country running today if possible (depends how much spare time I have).

I'm running the 2x at default clock (200Mhz) under Linux.

No, I don't support mode 7. In fact, I only support mode 1 at the moment. Transparency isn't on my priority list at the minute either.

My aim for this emu is to get one working as fast as possible, rather than one thats as compatible as possible.
 
i got my courage up and had a look at NK's snes emu's source code, but, not having any experience with that sort of programming, I was totally lost. I hope you stand a better chance. GOOD LUCK SQUIDGE!
 
My plan at the moment is to improve my graphics engine to support all modes apart from 7 as well as sprites, see how fast that goes and then throw the graphics code over to the second processor and see if the speed improvement is worth splitting further code that way.

If the remaining speed is over 30 fps (with sound enabled), then I may use that for increasing compatibility.
 
My plan at the moment is to improve my graphics engine to support all modes apart from 7 as well as sprites, see how fast that goes and then throw the graphics code over to the second processor and see if the speed improvement is worth splitting further code that way.
I don't know if this will help you, but the sound core used in SNES DS is open source:
http://pocketspc.pocketheaven.com/

It's written in ARM assembly, so perhaps it would be useful to you? It runs fullspeed on the DS, which is slower than the GP2X. Is it something you can use, or the the ARM9 in the DS not similar enough to the ARM processor in the GP2X?

I dont think the source to SNES DS has been released, but they took the same approach you're taking, which is why compatibility is fairly limited.
 
Last edited by a moderator:
Squidge, is your finished product is going to be open source since you're using source from other SNES emu projects? I'm not sure if the SNES sources you're using are open, but I'm assuming they are. It would be nice if you got one running well and then someone with a Zaurus could use your code to get one working there. I don't own a Zaurus, but I'm sure the people that do would be grateful.

Thanx,
Stan

Edit: Wow, I assume a lot don't I? Fixed it a little bit.
 
if you got a snes emu running as well as reesy got his genesis i would have to go nuts good luck :D
and maybe donate some money if i can find some between my couch cushions seeing as i spent it all on a 2x :D lol
 
Back
Top