-
Writeing an emulator?
Im thinking of trying to write an NES emulator, anyone get me started? More than just an emulator i want to make a program that just runs the rame, not necessarally emulates the NES hardware. Surely the rom contains all the data about how the game is played.
-
The term used for something that runs a game without emulating the hardware is "wrapper." And I'll try and point you in the right direction. My guess is that you don't want to backwards engineer an NES so what you'll want to do is find someone who can tell you how to decode an NES rom. Once you know what the binary is "saying" you can just write a program to do what the program is asking the nes to do.
As for writing an actual emulator. Get the full specs of an NES. And then look for the best way to utilize your hardware to act as if it were an actual NES.
On a side note. Nintendo looks very unkindly towards the development of any program/hardware that exploits its patented technologies. On a moral note, making emulators for anything is usually illegal. On a legal note, emulating anything Nintendo made should be pretty secret.
-
On another note you should have an extremely good handle on assembler if you really want to do an emulator. Most emulators load the rom into memory and then run it. The emulator is like a driver in memory that emulates the platform for the game. This is not a simple task at all unless you are a pro at assembly language. There are some things needed for an emulator that C just cannot do or do very well.
The legal and moral aspects, however, should be enough for you to abandon this project and move on to something more legal and ethical.
Thanks Eber for pointing out the legal and moral ramifications of this.
-
legal ramifications certainly, but is there really anything wrong with wanting to play ten year old games? and what if you own a nintendo (I do)? My nintendo still works, but I'm not so sure about the games... does my licensed right to the games run out when they wear out? Same goes for the nintendo? Hell, nintendo games are fun :) and I'm sure with the gamecube out and free gameboy advance emulators/development systems already out there, nintendo's legal department has bigger fish to fry.
-
If its such a big deal why is there so many NES emulators out there, i personally have a dozen N64 emulators, not to mention NES SNES NEO-GEO SEGA MAME and other emulators.
There is alot of grey aera in the whole emulation thing, I understand that as long as you dont attempt to sell an emulator its ok. As for roms, you are allowed a 'backup copy' of only games that you own.
Nintendo is cracking down on the N64 emus and roms, but I havent heard anything about problems with NES or SNES emulation lately.
I want to develop a way to give the nes games a facelift, I have had several ideas on how to this, some might be easy, others more complex. If I could figure out what exactly is on a .nes file i might could do something.
-
An important note to make about emulators and NES or any other nintendo platform is that Nintendo strictly prohibits making backups of games. So no matter how you look at it is, or at least nintendo says it is, theft. Bubba is right on about how an emulator works (usually). Since your cpu isn't the same as a NES'sit would be impossible for the game to run off of your hardware without making mario move at the speed of light. If you make a wrapper, then you should write a threading system that calls they cpu after a length of time as to simulate a 1.79mhz NES cpu. Since NES had a mere 4k of ram (thats including vram!) memory will not be an issue. Anyways, making an emulator is like writing a virus. Many programmers will do it merely because they can.