iNES_header[8] specifies how many RAM banks are there?

Discuss emulation of the Nintendo Entertainment System and Famicom.
User avatar
Petruza
Posts: 308
Joined: Mon Dec 22, 2008 10:45 pm
Location: Argentina

iNES_header[8] specifies how many RAM banks are there?

Post by Petruza »

According to http://fms.komkon.org/EMUL8/NES.html , the iNES_header[8] specifies how many 8KB RAM banks are present.

What's this exactly? Isn't the RAM internal to the Nintendo?
the iNES header specifies information related to the cartridge, not the Nintendo, as far as I know.

Are there cartridges with their own RAM banks?

And, isn't the RAM only 2KB mirrored four times?

And also, about CHR and PRG ROM banks, is there a doc on how is bank switching implemented from the standpoint of the emulator?
Is there any bank switching with Mapper #0 aka no mapper, aka NROM?
User avatar
67726e
Posts: 129
Joined: Sat Apr 03, 2010 5:45 pm
Location: South Carolina

Post by 67726e »

Are there cartridges with their own RAM banks?
Many developers found the supplied 2 KB to be inadequate and they used additional RAM that was put on the cartridges.
And also, about CHR and PRG ROM banks, is there a doc on how is bank switching implemented from the standpoint of the emulator?
Is there any bank switching with Mapper #0 aka no mapper, aka NROM?
As far as I know, there is none, but I might be wrong.
User avatar
tokumaru
Posts: 12668
Joined: Sat Feb 12, 2005 9:43 pm
Location: Rio de Janeiro - Brazil

Re: iNES_header[8] specifies how many RAM banks are there?

Post by tokumaru »

Petruza wrote:Isn't the RAM internal to the Nintendo?
The NES has 2KB of internal work RAM, and several carts have 8KB of extra work RAM, for a total of 10KB. That information in the header is for the few carts that have more than 8KB of RAM.
And also, about CHR and PRG ROM banks, is there a doc on how is bank switching implemented from the standpoint of the emulator?
There is information describing how each mapper works, but how they are implemented is totally subjective, and depends a lot on how the emulator is structured.
Is there any bank switching with Mapper #0 aka no mapper, aka NROM?
No.
User avatar
Petruza
Posts: 308
Joined: Mon Dec 22, 2008 10:45 pm
Location: Argentina

Post by Petruza »

Thanks!

So I'll delay mappers implementation to a later dev stage, for now NROM games, mainly SMB will do for testing and debugging of basic emulator functionality.

PS: Gee, I have the feeling I'm gonna get a bill any moment with the charge for all the advices I'm getting from this forum. :D
User avatar
Memblers
Posts: 4148
Joined: Mon Sep 20, 2004 6:04 am
Location: Indianapolis

Post by Memblers »

SMB is actually a rather tricky game for multiple reasons, you might be better off trying Donkey Kong or something if you want to get the most basic parts working.