RevEng Posted February 19, 2014 Share Posted February 19, 2014 I recently became aware of the Maria Specs document. Reading through it, I noticed that it states that character maps must be fast RAM, instead of ROM. (even in the slightly later version of the document.) Because this tidbit wasn't in the 7800 Software Guide, I've been accessing ROM based maps, and they appear to be working on real hardware. (though in retrospect, it is technically CC2's SRAM being accessed.) I'm hoping someone has a definitive answer... Did I get lucky with hardware tests, or is the MARIA Specs document wrong on this point? Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/ Share on other sites More sharing options...
PacManPlus Posted February 19, 2014 Share Posted February 19, 2014 That's funny; all of my games have character maps in ROM. I do remember, however, them saying that the DLs and DLL need to be copied to RAM, which I do. 1 Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2931753 Share on other sites More sharing options...
RevEng Posted February 19, 2014 Author Share Posted February 19, 2014 Ok, at least it has the virtue of being tested thoroughly! If its not an outright documentation error, maybe there's some kind of access speed difference between the mask ROMs of that era and EPROMs used today. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2931768 Share on other sites More sharing options...
tep392 Posted February 19, 2014 Share Posted February 19, 2014 Ok, at least it has the virtue of being tested thoroughly! If its not an outright documentation error, maybe there's some kind of access speed difference between the mask ROMs of that era and EPROMs used today. The same is true of Atari's published games. Maria accesses the character data directly from ROM. 1 Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2931786 Share on other sites More sharing options...
RevEng Posted February 19, 2014 Author Share Posted February 19, 2014 Excellent. Seems like a mistake in the MARIA Spec then. Thanks! Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2931787 Share on other sites More sharing options...
Rybags Posted February 19, 2014 Share Posted February 19, 2014 DLs you most often need to be changable so running from RAM is necesssary in that regard. I've seen it documented somewhere, ROM acccess is slower than for RAM. Remember, Maria runs based on ~ 7.2 MHz clocking. A CPU cycle is either 4 or 6 Maria cycles depending if TIA/RIOT is being accessed. A similar imposition exists when Maria is doing DMA, it's something like 2 cycles for RAM, 3 for ROM. Of course, Maria has no idea what is being accessed in the cart space so the assumption has to be that it's slow ROM whether it is or not. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2931798 Share on other sites More sharing options...
kenfused Posted February 19, 2014 Share Posted February 19, 2014 I take map to mean the "screen memory" and not the "font/character memory" correct? Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2931859 Share on other sites More sharing options...
RevEng Posted February 20, 2014 Author Share Posted February 20, 2014 In the 7800 Software Guide they define map as the data the DL points to in indirect mode. i.e. the "text" vs the character graphics. I assume it's being used consistently in the MARIA Spec. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2931954 Share on other sites More sharing options...
kenfused Posted February 20, 2014 Share Posted February 20, 2014 In the 7800 Software Guide they define map as the data the DL points to in indirect mode. i.e. the "text" vs the character graphics. I assume it's being used consistently in the MARIA Spec. That's what I thought. Just wanted to make sure everyone is using the same definition. I myself have always put the maps in RAM. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2932230 Share on other sites More sharing options...
Rybags Posted February 20, 2014 Share Posted February 20, 2014 Generally you'd want char codes in RAM except for static text like score/status lines. It was my thought that it didn't matter except that it took up more DMA slots. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2932255 Share on other sites More sharing options...
EricBall Posted February 20, 2014 Share Posted February 20, 2014 Indirect mode (aka character or tile mode) is specified by a 5 byte display list entry containing a 16 bit address pointer to the character / tile map in RAM (required?), the number of characters / tiles to display (i.e. bytes to fetch from the pointer) along with the horizontal position, the palette and the write mode flag. Each character / tile byte is used as the LSB for the address of the graphics data (which may be in ROM or RAM); the MSB coming from the CHARBASE register. Either 1 or 2 bytes of graphics data may be fetched per character / tile. As per the second link, MARIA has a different set of timings for graphics data (ROM) versus non-graphics data (RAM) accesses. I don't know whether MARIA changes timings based upon what kind of data is being fetched or the address (like it does to the 6502 for RIOT/TIA accesses). In addition, the cycle count list shows character maps taking 3 cycles - the same as a graphics byte. So it might be possible to put the character map in ROM; but as Rybags noted that's only useful for static data. (Hmmm... for SpaceWar! 7800, I had planned on including a tile based star field in ROM, I can't remember whether I ever tested it.) I wouldn't be surprised if the character maps could be in ROM since that's how you'd likely do a tiled background. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2932274 Share on other sites More sharing options...
Rybags Posted February 20, 2014 Share Posted February 20, 2014 Surely there might be some games out there that use Rom-based characters, although there's little extra effort in copying static stuff to Ram. Of course the timing difference Rom vs Ram if it is the case gives incentive to put as much into Ram as possible. Also, character mode can be somewhat more DMA intensive since the char code fetches are on every scanline. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2932276 Share on other sites More sharing options...
CPUWIZ Posted February 21, 2014 Share Posted February 21, 2014 In case anyone is interested, I just tried CHARBASE in 320 mode at $3000 (EPROM), works just fine and the EPROM is slow. EDIT: Just tried $1000 as well, no problem. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2932772 Share on other sites More sharing options...
Rybags Posted February 21, 2014 Share Posted February 21, 2014 Can you work out if the accesses are slower than if from inbuilt RAM though - or is "the EPROM is slow" inferring that they are? Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2932783 Share on other sites More sharing options...
CPUWIZ Posted February 21, 2014 Share Posted February 21, 2014 I think the reality is, that Maria isn't all that happy with really fast RAM (I think it was a UM61256K-15, Sirius will not work properly on that speed of RAM), so I don't think it matters. Are you wondering if you can gain cycles with placement in RAM vs. ROM? RevEng was just wondering if it is possible, and I say, yes it is. Big time, since I just mapped it to $3000, I think the HSC does map characters into that area as well, come to think of it. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2932798 Share on other sites More sharing options...
Rybags Posted February 21, 2014 Share Posted February 21, 2014 Yes, the query was the # of cycles RAM vs ROM, or I guess a precise term would be what Maria thinks each is because of course RAM can be mapped in the cart area but Maria doesn't know what it actually is. It all gets a bit convoluted since we have the "fast" clocking at ~ 7.2 Mhz, then the various access speeds and the 6502 running at either /4 or /6 speed depending on what it's trying to do. Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2932857 Share on other sites More sharing options...
EricBall Posted February 21, 2014 Share Posted February 21, 2014 It's not the CHARBASE which is in question, but the character list pointed to by the display list entry. 1 Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2933052 Share on other sites More sharing options...
CPUWIZ Posted February 21, 2014 Share Posted February 21, 2014 It's not the CHARBASE which is in question, but the character list pointed to by the display list entry. Also not an issue, I have sprite data mapped to $3000, the display list references them. Is that what you mean? Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2933075 Share on other sites More sharing options...
EricBall Posted February 24, 2014 Share Posted February 24, 2014 Also not an issue, I have sprite data mapped to $3000, the display list references them. Is that what you mean? Maybe... are you referring to the graphics data used by a normal direct sprite, or the list of LSBs which are added to CHARBASE to obtain the graphics data (indirect sprite). It's that list of LSBs which are in question (RAM vs ROM). Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2935180 Share on other sites More sharing options...
kenfused Posted February 25, 2014 Share Posted February 25, 2014 Also not an issue, I have sprite data mapped to $3000, the display list references them. Is that what you mean? Not sprite data, or character data (definitions) but the character map that picks the characters to display has to be in RAM (or at least that is what the docs say) Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2935696 Share on other sites More sharing options...
CPUWIZ Posted February 25, 2014 Share Posted February 25, 2014 Well, I have a scroll text in something upcoming, that scroll text defines the characters to display (ASCII - big surprise). I move two "windows" across it, to get 320 scrolling. It and the character data live in ROM. 2 Quote Link to comment https://forums.atariage.com/topic/222256-character-maps-in-rom/#findComment-2935701 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.