Ask Slashdot: Understanding the SNES? 157
An anonymous reader writes "As a product of the 90s I grew up loving the classics that kids today know about from Wikipedia and pop-culture references. Games like Super Bomberman, Zelda: A Link to the Past, Donkey Kong Country I and III (II was a sellout, come on) are the foundations of my childhood memories. Now, though, as a fourth-year electrical engineering major, I find myself increasingly impressed by the level of technical difficulty embedded in that 16-bit console. I am trying, now, to find a resource that will take me through the technical design of the SNES (memory layout, processor information, cartridge pin layouts/documentation) to get a better understanding of what I naively enjoyed 15 some years ago. I am reaching out to the vast resources available from the minds of the Slashdot community. Any guide/blog series that you know of that walks through some of the technical aspects of the, preferably, SNES (alternatively, NES/Nintendo 64) console would be much appreciated."
superfamicom.org (Score:5, Informative)
Re: (Score:2)
Lighten up, Francis!
Re: (Score:2)
Re: (Score:2)
No one even suggested a 25% probability except you, buddy. Go outside, take a few deep breaths. It helps, I promise.
Re: (Score:2)
Re: (Score:2)
Whoa, changing your sig works retroactively on posts you've already made!? I had no idea!
As you were, Immerman, as you were. ;)
Re: (Score:2)
Nowhere does it say, or even imply, that each of the four possibilities is equal. Only that there are only four of them.
As you yourself immediately pointed out in your own more verbose example, four possibilites does *not* mean a 25% chance of each.
Re: (Score:2)
rather than reply to all the counter-comments individually, tepples' sig has been changed since we had our conversation, apparently the changes apply retroactively to existing comments.
take one apart? (Score:5, Informative)
you're a 4th year EE student, why not just take one apart?
Re: (Score:1)
especially while you might have access to the schools facilities, if it is a bigger research school you might be able to sweet talk someone into x-raying stuff for you.
Re: (Score:1)
Probably difficulty of finding one. In my area we have a lovely chain called "Slackers" that sells old consoles, and you might be able to get an SNES for about $40 if they have one in stock. However, stock is very limited and between more and more of the older consoles dying and collectors, the stock is becoming more and more limited. Could be in their area, that the difficulty of finding one makes the chances of finding one to disassemble highly unlikely, especially if they wanted one that was in workin
Re: (Score:1)
Probably difficulty of finding one.
There is nothing at all difficult about finding an SNES on eBay.
just buy it. (Score:2)
I have 3 I picked up on ebay for cheap. I just kept low bidding until I won as many as I needed. If you're in a hurry you can just bid $60 and get it with controllers and power supply. Most GC/N64 video cables work in the SNES, so don't worry too much about finding that if it doesn't come with one. In a pinch there are a lot of after-market replacement parts on Amazon and ebay for fixing them up.
Re:take one apart? (Score:5, Insightful)
you're a 4th year EE student, why not just take one apart?
The SNES uses custom chips for most of its functionality. Unless he has access to decapping facilities, taking one apart will provide only limited information.
Re: (Score:2)
you're a 4th year EE student, why not just take one apart?
The SNES uses custom chips for most of its functionality. Unless he has access to decapping facilities, taking one apart will provide only limited information.
I'm an ME, so I don't know much about reverse engineering electronics.
maybe this will help?
http://s3cu14r.wordpress.com/2010/07/15/boiling-chips-in-tree-sap/ [wordpress.com]
Re:take one apart? (Score:4, Interesting)
I'm an ME, so I don't know much about reverse engineering electronics. maybe this will help? http://s3cu14r.wordpress.com/2010/07/15/boiling-chips-in-tree-sap/ [wordpress.com]
I use to occasionally decap 'plastic' ICs, which are typically molded using an epoxy based compound. We always used fuming nitric to open those. We used a dropper to put the heated nitric on the top of the package, the goal being to have the pins intact and the device functional afterwards. Not real safe unless you have the proper equipment and know what you are doing. Later we had commercial equipment that did pretty much the same thing.
I suspect the rosin used in the link only works on some types of non-epoxy based plastics.
Re: (Score:2)
you're a 4th year EE student, why not just take one apart?
The SNES uses custom chips for most of its functionality. Unless he has access to decapping facilities, taking one apart will provide only limited information.
This might be a stupid question, but is it not very EE-like to do something cool like taking one apart and making his own portable SNES a la benheck [benheck.com]?
Re:take one apart? (Score:5, Insightful)
you're a 4th year EE student, why not just take one apart?
Unfortunately, EE is not like ME. What happens in an electrical circuit is almost always invisible to the naked eye. Monitoring high-speed digital signals takes special (expensive) test equipment, which even a university lab might not have lying around for open use. Even figuring out a schematic can be hard if you're dealing with multi-layer circuit boards and custom integrated circuits. The ICs in a SNES are all surface mount, which means even more specialized equipment and skill to remove them with no easy way to work with them afterward. Do a Google Image search for "SNES mainboard" and you'll see what I mean.
Also, simply being a fourth-year student doesn't necessarily qualify him to reverse engineer a console. Digital electronic systems are orders of magnitude more complex than mechanical ones, and EE coursework tends to focus more on theory than practice. I'm not saying it's impossible, I'm just saying that going solo is probably not the best idea for his first foray.
Re: (Score:3)
Monitoring high-speed digital signals takes special (expensive) test equipment, which even a university lab might not have lying around for open use.
The SNES does not have high-speed digital signals. The whole thing is clocked at 3.58MHz. This isn't like trying to probe a SATA connection.
Re: (Score:3, Insightful)
3.58Mhz might seem slow compared to modern electronics, but I'm pretty sure that "3.58 million signals per second" is still considered high-speed. Sometimes these terms are relative to the kind of electronics you could feasibly put together on your own (say for a physics class lab) rather than whatever whiz-bang tech is on the market (read: engineered for years by professionals).
Re:take one apart? (Score:5, Informative)
The SNES does not have high-speed digital signals. The whole thing is clocked at 3.58MHz. This isn't like trying to probe a SATA connection.
Sorry, poor choice of words. Regardless, he'll need a logic analyzer, and those are a lot less common than oscilloscopes. He could probably find a cheaper one on eBay if he really wants to reverse-engineer the hardware.
Re: (Score:2)
Actually, the central clock is 21.47mhz, the bus frequency can be that divided by 6,8 or 12 depending on what you are doing.
You can access the raw clock on a couple of pins that go to the cartridge, the superfx coprocessor in cart divided it by two to get operating freq, sfx2 was a 21mhz risc processor in a cart.
Re: (Score:1, Funny)
I need a senior project for EE but don't want to be bothered doing it myself, or even googling for it. Do it for me?
TY,
OP
P.S. I like vidya games, so something like that maybe?
Re: (Score:3)
Re:take one apart? (Score:5, Insightful)
If you guys keep disassembling Super Nintendos (and PS1s and Atari 2600s and N64s) pretty soon there won't be any left for us to play. It will end-up like the Japanese Zero airplane (only two left). It saddens me to see people destroying an item that is no longer being made & therefore becoming more-and-more rare with each passing day.
Re: (Score:2)
I sort of agree with you (though I took apart a 2600 for a college project in the early 90s), though at least for the "for us to play" part, some of the backward compatibility helps there.
I don't have a Wii, but their online game store for older games is very intriguing to me (even though I never had a NES or SNES, though played some of the latter on friends' machines). Maybe after the Wii U comes out, even more people will dump Wiis so they'll be really cheap. (It's not like I don't have the money, but I
Re: (Score:2)
Forget the Wii store. Install the Homebrew channel and an assload of emulators. I wasted way too much money the first night I had my Wii just because I was too lazy to mod it.
Re: (Score:2)
I would rather use the Wii store since it's a legit way of getting the games(*). $5-$9 (using low-high end for NES & SNES games, listed on the wikipedia page for Wii Points) seems reasonable to me, esp since I didn't have the games originally.
(*) If I could buy legit arcade ROMs to use in a MAME machine, I'd probably do that too.
Re: (Score:2)
Re: (Score:2)
Re: (Score:2)
https://www.google.com/search?q=do+a+barrel+roll [google.com]
Check out Byuu's stuff from BSNES. (Score:5, Informative)
http://byuu.org/articles/
Byuu is the guy who wrote bsnes, which is a 100% accurate SNES emulator written specifically to emulate it as close to the hardware layer as possible for the sake of preserving the system.
Re: (Score:2)
Re:Check out Byuu's stuff from BSNES. (Score:5, Informative)
Also from Byuu: an article at Ars Technica about accuracy in SNES emulation [arstechnica.com].
Re: (Score:2)
Re: (Score:2)
except it doesn't support simple stuff like fullscreen mode changing, which makes vsync, a needed part of accurate emulation, nearly impossible.
vsync is NOT a "needed part of accurate emulation" (Score:4, Informative)
vsync might be nice for the user experience, and I'll be the first to admit that bsnes does not have all of the little user conveniences that some older (faster, less accurate) emulators have.
I personally prefer to still use a many-years-old version of ZSNES for actually playing emulated games.
But in terms of accuracy in its emulation of the SNES hardware, BSNES is unbeatable. Byuu-san was always disgruntled about the lazy approach that other emulator authors were taking, towards accuracy--using known-inaccurate techniques and lots of game-specific hacks to cover up any problems--but several years ago he decided to do something about it, and since then he has emerged as one of the most dedicated and careful (and innovative) of the small group of world-class developers reverse-engineering the behaviour of the SNES. Byuu has made literally dozens of unique findings about tiny, obscure behaviours of the SNES hardware--in many cases even things that *no known game even depends on*, but he spent the time and effort to devise theories and write tests and do experiments in order to get a deeper understanding of what was going on. And then incorporating those findings into BSNES in the clearest and most accurate way possible.
The result of this years of super-human effort, is an emulator (BSNES) that is a lot slower than certain other emulators, but also much more accurate in the precise details. It can run every known SNES game (thousands of them) very accurately, with absolutely NO game-specific hacks in it. Which is an amazing accomplishment, and a valuable resource for others to learn about SNES programming (either emulators or games), and I am positive that someday, BSNES will be a key piece of efforts to preserve the history of SNES games so that future generations can learn about them and play them.
Half and half frame != accurate (Score:3)
vsync might be nice for the user experience
Even if your emulator generates an accurate sequence of bitmap images representing consecutive frames of PPU output, it is not very accurate to send half of one frame and half of another frame to the monitor.
Resampling audio produces least inaccuracy (Score:2)
You could also argue that resampling the audio to get smooth audio+video at the same time is not accurate, and you'd be right. Except for the fact that perfect video+audio sync without doing that is impossible on modern hardware.
That and the fact that resampling audio to a different sample rate is much better understood (and in fact provably reversible according to Nyquist) than resampling video to a different frame rate. I may be a pedant, but I'm also a pragmatist who recognizes that the lesser of two evils is the often the best available. So if your video card runs at 58.7 to 61.5 Hz, then resampling the audio is probably the least inaccurate way to keep them in sync.
Comment removed (Score:5, Interesting)
Re: (Score:1)
Re: (Score:2)
Zophar.net (Score:1)
Zophar.net has an AMAZING series of documents on the workings of the SNES on the hardware level. Look specifically for the doucmentation written up by Yoshi! and anything from the various Emulator Teams. (The Dumper, zsKnight, _Demo_, Byuu, Marcus C., etc)
Zophars Domain has been my emulation resources, and the starting point for all of my console research since at least 1999.
Re:Zophar.net (Score:5, Informative)
Be careful. A lot of that stuff at Zophar's Domain is way out of date. Much of it is based on speculation or trial-and-error emulator testing or is flatly incorrect.
Re: (Score:2, Informative)
Correct - at least one document on Zophar's is wildly inaccurate (I know because I wrote it!)
SNES9x source code should help (Score:4, Informative)
The source code to a very good SNES emulator is available here: http://snes9x.ipherswipsite.com/ [ipherswipsite.com]
Re: (Score:2)
You can also find SNES controller, cartridge and video connector pinouts at pinouts.ru [pinouts.ru].
NesDev (Score:2)
bsnes, the only 100% accurate emulator (Score:5, Informative)
Even aims for cycle accuracy.
http://byuu.org/bsnes/ [byuu.org]
It's a great design (Score:5, Funny)
Especially interesting is the special circuitry that eliminated the need to blow air into the cartridges that plagued the original NES.
Re: (Score:2)
Especially interesting is the special circuitry that eliminated the need to blow air into the cartridges that plagued the original NES.
"Golden!"
Re: (Score:1)
You just never learned how to press the cartridge in at the perfect grinding angle.
Re:It's a great design (Score:5, Interesting)
Especially interesting is the special circuitry that eliminated the need to blow air into the cartridges that plagued the original NES.
The need to blow air into cartridges on the original NES was a result of DRM.
No, seriously.
The NES console contained a chip called the CIC [nesdev.com], which had to perform a handshake with a corresponding CIC on the cartridge, or else the system wouldn't boot (and you'd get that blinking red power LED). The purpose of this was to ensure that no one could manufacture NES cartridges without the approval of Nintendo of America. Unfortunately, it also made the boot process far more finicky; even the slightest amount of dirt would cause the handshake to fail and the system to repeatedly reset. (The fact that Nintendo used a weird ZIF-style connector rather than a standard card edge connector didn't help, either. This was done because they didn't want the NES to look like a standard game console, which had a bad reputation after the 1983 crash.)
CIC failure vs. PRG failure (Score:2)
Re: (Score:3, Interesting)
Re: (Score:2)
How Color Dreams reversed the polarity (Score:3)
Re:How Color Dreams reversed the polarity (Score:4, Funny)
That'll show everyone who laughed at Nintendo when they hired Geordi LaForge to work on the SNES...
Re: (Score:2)
If your NES's power LED blinks when you put in a cartridge, it's a problem with the 10NES copy-protection chip - if the chip doesn't handshake, it continually resets the CPU. If it's not blinking, you've just got a bad connection and your problem is likely with the cartridge connector.
Re: (Score:2)
The need to blow air into cartridges on the original NES was a result of DRM.
No, seriously.
That's a bit of a stretch. The ZIF connector and dusty contacts are the primary culprits in the "need" to blow on NES carts. Sure, the CIC chip causes problems on occasion, but it's not nearly the culprit people make it out to be. You can't blame the CIC, for example, when you get vertical lines on the edges of all of the on-screen sprites, and most of the blinking-light errors just turn into solid light errors once you disable the lockout chip. I have two NES systems, one with a disabled lockout chip a
Re:It's a great design (Score:5, Informative)
If anyone has an NES with the blinkies, you can disable the CIC by snipping one pin [imageshack.us].
SNES (Score:1, Offtopic)
>> SNES
Gesundheit
DKC II was the best in the series.. (Score:1)
Start out with the Gameboy. (Score:5, Informative)
Of all systems I looked into, I found the gameboy the easiest to understand. The underlying CPU is quite simple. The LCD display is quite simple to understand, there are not a huge amount of complex registers to understand, and it's not that timing critical. (Unlike the NES, which depends a lot on instruction timing)
Re: (Score:3)
I would say SNES was the most technically pushed (Score:3, Insightful)
Re: (Score:2)
You can't really say that the SNES was pushed that hard when it used chips contained in the cartridges for the really impressive stuff.
Re: (Score:3, Insightful)
Dev manual (Score:2, Informative)
I have programmed an assembler and written my own games for the SNES. I use this manual quite often:
http://www.romhacking.net/documents/226
It's a leaked dev manual. It doesn't have everything, but it's a great resource.
Not just *NES (Score:2)
If you're interested in the process for the craic of the engineering rather than just being a NES fanboy, you could learn a lot from learning the history of the game "Elite" which pushed hardware and software boundaries phenomenally. In fact I'd be curious if anyone could come up with a more impressive game on that front. The best account I've read is in the book Backroom Boys [guardian.co.uk] (abridged but good version of the Elite chapter in the link) which I can heartily recommend not just for the chapter on elite but th
Re: (Score:2)
There's also the Sonic games on the Mega Drive, which pushed the boundaries of the technology of the time, especially with respect to speed.
*sits back and waits for the inevitable Sonic haters :)*
Re: (Score:2)
I never was a massive Sonic fan, but playing it again now - on a real Megatrive, at that - I'm amazed at how smooth and fast it is. No, actually, amazed isn't the right word. I don't notice how smooth and fast it is. It's just smooth, and fast. The gameplay is so slick and transparent, with no horrible juddery slowdowns.
Jeez I wish modern games played like this. Just one more shot...
SNES has Blast Processing (Score:2)
I never was a massive Sonic fan, but playing it again now - on a real Megatrive, at that - I'm amazed at how smooth and fast it is.
You might be tempted to attribute this to some mystical "Blast Processing" capability of the Mega Drive/Genesis chipset. But Blast Processing is just Sega's term for DMA-assisted copies to VRAM during vertical blanking time. The NES doesn't have it. Sega's marketing department made a big deal about the Genesis having it, but the Super NES has it as well.
Re: (Score:2)
Yeah, it's basically a crude blitter. It still looks pretty damn cool.
Re: (Score:2)
That reminds me of something I noticed with the NES game Gradius II - that stage with the ice crystals that break when you shoot them... having the Vic Viper, 4 option shadowing, all of those shooting a ripple laser and twin missiles ON TOP OF enemy ships flying and shooting at you AND the ice crystal things moving around and splitting when you shoot them....
Re: (Score:2)
Re: (Score:2)
I agree that Elite is a technical tour de force, but perhaps a more impressive game is Exile, also on the BBC computer. It could run in 32K RAM and used a procedurally generated landscape, had a decent physics engine, a "realistic" form of AI for the creatures and was absolutely huge.
The most amazing thing (to me) is that problems in the game were solved not by following some pre-programmed rule (put "key A" into "door C"), but by manipulating the environment. So "key A" did fit "door C", but you could also
emulators (Score:2)
The information you seek is also quite useful for SNES emulators.
Try going to the snes9x, zsnes, bsnes, and other such sites and lurking.
Re: (Score:2)
Be careful though from drawing conclusions about how the hardware works from emulators: some emulators try to mimic the hardware as closely as is practical, while others only implement the behavior necessary to make the popular games run.
The accurate emulators are more likely to implement the actual hardware behavior, as the behavior-based approach quickly falls apart with a big software library: if you add a hack to fix the behavior of one game, you often break another, while if you emulate the hardware re
Open SDK (Score:2)
Not exactly what you asked for but snes-sdk is a tinycc-based C compiler and SDK for the SNES. Pretty cool if you want to write your own games and don't want t write everything in assembly.
http://code.google.com/p/snes-sdk/ [google.com]
First steps in reverse engineering (Score:5, Insightful)
Your first step in reverse engineering aka total mastery of a device should be something a little simpler, like a 2600 or a PDP-8 or if you "demand" something modern, perhaps a very small (pun intended) microcontroller like the pic 10F family. You don't mention any previous experience with reverse engineering so I assume you have none.
Because they scale non-linearily, reverse engineering something simple and something hard doesn't take 200% as long as just reverse engineering something hard, it takes more like 100.1% longer, so the tiny extra investment isn't going to slow down the overall project too much. However the experience you gain figuring out the simpler thing Might dramatically reduce the time taken to figure out the hard thing.
The standard /. car analogy is you probably should start with learning how to change the oil before you try to rebuild the engine.
Its not a hazing thing or making fun of noobs, its just good practical educational advice. Trying something way beyond your level at best results in frustration, at worst in a sorcerers apprentice disaster.
Re: (Score:2)
actual bench work started with top and bottom overhauls
Must have been pre ASVAB. I still remember taking that test before enlisting and being able to answer the questions, but being mystified as to why I'm answering questions about labeling parts of a turbocharger and which way to turn the wrench to loosen the bolt and given 9 gears in a geartrain complete with a locked differential in the middle, if you rotate gear 2 clockwise which direction does gear 6 rotate? The electronics too... Reminded me of my ham radio general license written, although I was way be
Re: (Score:2)
The ASVAB is a placement test. Depending on your scores in various areas, it makes it easier for them to place you based on your answers for mechanical, electrical, language ability, math skills, etc...
It isn't a test like say, the SAT, it's more of an aptitude test.
ASVAB: Armed Services Vocational Aptitude Battery
there's a book in the works (Score:2)
This doesn't much help you now, but I've been told that the MIT Press Platform Studies [platformstudies.com] series, which looks at both technical and cultural/artistic aspects of gaming platforms, and how those aspects impact each other, has an SNES book in the pipeline. May want to look for it later. They just came out with one on the Amiga [amazon.com] that was pretty interesting, so hopefully the SNES one will be good, too.
I/O Pinouts (Score:2)
This might make a good addition to whatever you can glean from an emulation discussion since emulators don't typically deal with the external connections.
SNES? (Score:2)
Have you picked your phone up to call Nintendo? (Score:2)
I mean, seriously... Companies in general, and corporate giants in particular, aren't too willing to share information, much less potentially confidential documentation. But I've never heard of any company refusing a wide range of information when called by a student introducing himself as such -- especially on obsolete products. Heck, if activists can make it into poultry farms when presenting themselves as agriculture students, surely you can wiggle yourself into finding a few proud engineers at Nintendo
HDMA was awesome sauce (Score:2)
The SNES had eight HDMA channels, each of which could feed data from a table into a specific display hardware register on every scan line. The first thing I programmed on the SNES was a company logo sequence that used seven HDMA channels (which you can see in the first 12 seconds of this video [youtube.com] if you care.
When I later moved on to the GBA, I was aghast to see that the HDMA channels were gone from the hardware. To me, that was a big step down. :(
By the way, though the SNES is a 16-bit machine, it actually doe
Re: (Score:2)
What are you talking about?
The GBA does support hblank DMA, which lets you write new values for each background layer's scrolling and control registers. I use it all the time.
It's just not specifically called "HDMA" anymore, it's rolled up into regular DMA instead. Use incrementing source, and incrementing+reset destination, write the first value during vblank time, and you have HDMA.
Because many registers are adjacent in IO memory, you can get multiple effects with a single DMA transfer.
Google "FPGA SNES" (Score:2)
Lots of interesting stuff to read!
Why ask here? (Score:2)
I don't see how anyone capable of understanding the technical aspects of a video game console would need to ask such a question on Slashdot.
When I wanted to know how these consoles worked, I Googled it, and I learned everything I needed to know. All of the earlier Nintendo consoles have been heavily documented by fans. I never had to ask anyone anything, and was eventually able to make my own ROMs for NES, SNES, GB, and GBA. I later took this knowledge further and made my own NES Flash cartridge, albeit o
Re: (Score:2)
Try it. Warez sites tend to crush useful stuff from the results.
Re: (Score:2)
I'm sure there's a torrent available at Demon... Oh wait.
Re: (Score:1)
Re:The Ultimate Resource for SNES Development (Score:5, Insightful)
Because of things like this. [slashdot.org] Sometimes it's good to have a current, real-time discussion with a range of knowledgable people, rather than searching the entire fucking WWW and figuring out for yourself who got what right and wrong.
Re: (Score:2)
Sootman:
I agree with you that its good to have a current, real-time discussion with a range of knowledgeable people. Where we differ is he could easily have searched for "SNES hardware forum" or "SNES hardware disccusion" or even "SNES hardware specifications" and found a better place to ask this question, or even found that it was asked already and answered.
I searched for "SNES hardware specifications" and the number 1 search result took me to a SNES hardware discussion forum that appears to be pretty acti
Re: (Score:2)
AC:
Actually yeah, I did easily come across the information he was looking for, by searching for "SNES hardware specifications" and clicking on the top search result, and reading. It took me to this forum where people are actively discussing SNES hardware specifications and posting links to the information he requested. Here is an excerpt from the first post on the page google linked me to:
Here's is a new decoument with SNES hardware specs,
http://nocash.emubase.de/fullsnes.htm [emubase.de]
http://nocash.emubase.de/fullsne [emubase.de]
Re: (Score:2)
AC:
Ok, you are right about it being Ask Slashdot and not a proper article. I just don't see why you would use Ask Slashdot to replicate the same answers that could be found in a discussion board for SNES hardware, a discussion board that could easily be found by searching for it on a search engine.
I can understand it if there weren't any resources for the question readily available, but there are a lot of people out there that are interested in SNES hardware and SNES hardware emulation. These discussion boa
Re: (Score:1)
Your snark would be more compelling if THIS VERY DISCUSSION weren't a top five result for the search in question.
Re: (Score:1)