SNES (Super Nintendo Emulated System)
With a spare SNES cartridge connector I had been kicking around, and a taken apart console I previously had been gutting parts from, I had all the motivation I needed!
I started by lining up a perfboard with the spacings of an original SNES motherboard, and cut holes in the perfboard to line it with the case. I then lined up the spare SNES cartridge connector I had to fit the cartridge opening on the top half of the case, as it’s the one part of the motherboard that absolutely had to line up.
I had also desoldered the back IO plane from the original SNES motherboard as the power connector is a part of the plastic. The standard AV port was also desoldered, and I was pleasantly surprised to find that it’s component pins were spaced the standard 0.1″ apart. So I was able to drop it right into the perfboard. As you could see from the image below, lining these few components was a relative breeze..
To interface the cartridge port to the Raspberry Pi, I had originally decided to use Microchip MCP23S17 SPI-based IO expanders, but I had also bought it’s sister chip, the MCP23017, which is I2C based. Both versions allow the expansion of 16 I/O pins. Expanding the Pi’s GPIO pins are a necessity given the number of I/O pins a standard SNES cart uses; 16 Address, and 8 Bank control pins, along with 8 Data out pins, and at least 4 control pins. Totaling 36 pins needed to read most carts. I would need to use at least three of these expansion chips.
The SPI version of the expander has a 10MHz communications clock, while the I2C version only has a maximum 1.7MHz clock. Also, the Raspberry Pi has had notoriously slow I2C drivers, with a configured clock rate of only 100KHz. Despite the obvious speed advantages of the SPI bus, I found that code examples were lacking. I also realized that I would need to run additional bus wire, on what would be a very populated hand soldered board. On top of that, I had a P82B96PN I2C level translator ready to use, and with SPI I’d have to level translate additional lines, because the Pi uses 3.3v logic, and all the SNES components uses 5v logic.
As you could see above, hand soldering all these pins was not for the faint of heart, and this was only the beginning! It was also around this time that I had the idea of utilizing the unused Ext Port door for USB, thus the USB socket above. The pin headers on the top center were to connect a daughter-board where the Pi was going to rest..
I decided to not go with a PCB daughter-board in the end as I didn’t want a permanent extension of the main PCB as I may need to solder under it. Nor did I have the female headers to make it removable. Plus, it added unnecessary complexity. In the end I went with an Adafruit’s GPIO ribbon cable to connect the Raspberry Pi to the perfboard. I desoldered, and cut up a 40-pin female IDE header from an old motherboard, and dremeled it down to the 26-pins the ribbon cable needed, and made a spot for it.
It was around this I started focusing on powering the system, and a way to safely power down the system with the stock power switch.
Next up, DC-DC converters, Arduinos, and MOSFETs. Oh my!
Oh my god. I LOVE that! How awesome to play anything emulated on the original hardware. Plus carts!
Pingback: Turning a Raspberry Pi into an SNES | Daily IT News on it news..it news..
Congrats for that neat project!
Might be a silly question (as questions usually are) but assuming someone who can write / edit / hack, would it be possible to address the speed issues by throwing two Pi’s in the box, one to handle the graphics, the other to handle sound and other I/O rather than waiting for a faster PI?
Very nice project, congratulations!
I still have two SNES in perfect working condition 🙂 They are bullet proof console!
Can you post the wiring you did for this? Rather than just showing off? 😛 JK man, very cool
Andy, I have actually considered something along those lines. I hadn’t considered offloading audio and I/O to a second Pi, I had just imagined spitting the threads, but your suggestion sounds better. Thanks for the tip! 😀
I’m not exactly sure how I would pull it off though. I could link both Pis via GPIO, or Ethernet. I’m guessing GPIO communications would be the best, but I lack the skills needed for re-coding major portions of the emulator.
Shake, there are no schematics. I wired the level shifters by the datasheets, and actually screwed up a few times due to the fact I was wiring on a whim.
As for the other components, the Arduino sketch has the pin numbers for power management, and the cart_reader.py script could clue you in to what cart pins go where. Also because you asked, I appended a spreadsheet I used for the cart to my GIT. 🙂
Why is not in fullscreen?
This is very interesting, but I must find a broken SNES console and buy another Pi (my only one is in use).
Very awesome project, congratulations.
You win 1 Internet Sir. Well done!!!!!!
Would it be possible to release a fast snes emulator which we can use with the RasPi? Every snes emulator I tried was very slow.
The cart reader aspect is pretty awesome!
>> offloading audio
Maybe a USB soundcard with its own processor might be able to help.
I’m just about to start doing the same thing as you yet to buy the raspberry Pi but got the broken snes lol 🙂 now who still got me soldering Iron lol
You are a god amongst men Ted. Awesome project. Well done.
Hey! I could have sworn I’ve been to this site before but
after checking through some of the post I realized it’s new to me.
Anyhow, I’m definitely delighted I found it and I’ll be book-marking and checking
back frequently!
Hey I’m working on a similar project but my work is nothing compared to yours nice work.
Hey! Nice job! Is it possible that you publish the material list and the solder layout. I realy love to reproduce this ’cause my old SNES start to bug :/.
Excellent site you have here but I was wanting to know if you knew of any forums
that cover the same topics discussed in this article?
I’d really like to be a part of community where I can get feedback from
other knowledgeable people that share the same interest.
If you have any suggestions, please let me know. Thanks a
lot!
Feel free to visit my web blog http://www.huishige.com
Hey just wanted to give you a quick heads up and let you know a few of the images
aren’t loading properly. I’m not sure why but I
think its a linking issue. I’ve tried it in two different
browsers and both show the same results.
Another interesting project would be to put an raspberry pi in a snes cartridge which emulates an snes game on the cartridge pins. That would make it possible to play any rom with the original untouched snes 🙂 that would also make it possible to play custom roms, to build a simple web browser or an mdp client and much more, everything with the original untouched snes hardware 🙂 And who knows what you could do with the snes when you extend the snes with the 16 Bus B Expansion Chip Pins (or the ext port) and the help of the raspberry pi..
Pingback: 5 Old School Gadgets You Can Create With a Raspberry Pi | Retro Gamer
Pingback: 5 Old School Gadgets You Can Create With a Raspberry Pi | Retro Bunny
Hello. I really admire your work. Congratulations.
I wanted to run Gameboy & Gameboy color cartridges with the Raspberry Pi 3B.
Do you believe to be possible? Basing their work believed to be viable?
Can you clarify some doubts if I need it?
Thank you very much.