Jump to content

Colecovision Ram

Recommended Posts

I am reading Tony Cruise's excellent book as far as addressing the 1k of Coleco memory.


His library addresses Coleco Ram at $7000 to set up stack pointers, sprite pointers and the like.

However the way I have always perceived the Coleco Ram as being mapped to address $6000 to $63FF


Could someone point out the disconnect, maybe it is because I have been working late as well as being a beginner.


$0000-$1FFF 8K BIOS ROM

$6000-$63FF 1K RAM



I PM'd him but I suspect that he is busy and this is one of those deals I am trying to work out asap


Other websites have said that the 1k Ram is mapped into $6000 to $7FFF.

My Hex may be off but that equals to 8k not 1k

Edited by Captain Cozmos
Link to comment
Share on other sites

  • 1 month later...

I always use the $6000 cause its easier when using emulators to debug code.

I think somewhere it was even discovered that games could write to $6000-$3fff, and later in the code use $7000, maybe it was done by another programmer, but might be quite confusing ;)

I will also make it incompatible with the adam, cause $6000-$7fff, is not mirrored at the Adam.


Link to comment
Share on other sites

Regardless, in order to be completely legit I have reset all addresses that were $7000 area to $6000


My feeling is to always go with the engineers and factual design of the system to avoid conflicts.


The ADAM is actual physical space so $7000 is not $6000 or $5000

So I suspect that when you set a memory address to $7000 on the Colecovision it returns $6000 because it has nowhere else to go.


You would have to ask Mr. Cruise why he put $7000.


I am working with the creator of Gear Coleco and he is the one who corrected me on all of this because I said his emulator was in error when in fact it is Mr. Cruise's library that relies on a Colecovision system error of sorts to map it correctly.  As far as I am aware he is not writing for ADAM in the first place so in a technical sense Mr. Cruise is not wrong but at a level of being correct I would not rely on a bug in order for my work to run.


Is this the reason why Scramble does not run on the ADAM without a patch?

Edited by Captain Cozmos
Link to comment
Share on other sites

I'm not a programmer but can at least relay information that was provided to me by several sources when producing the CV ROM Update Project.  Referring to my notes in the attached:


Page 13 - "Coleco documentation states that the official location for RAM starts at 0x7000", i.e.:




Page 24 - "The architecture of the ColecoVision allows for 8K of RAM, but to cut costs, Coleco only put 1K of RAM in the console, positioned at 0x7000-0x73ff within the main addressing range. The other 7K within the allowed 8K range are mirrors to that 1K of RAM. So if the game software writes a value at 0x6000, it's actually written at 0x7000 within the console hardware. When a CV cartridge game runs on the ADAM, the ADAM's native 24K of RAM is used by the software. This means that there's no mirroring involved: if you write at 0x6000, you're NOT writing at 0x7000."


This is reinforced by Amy Bienvenu's CV Programming Guide from 2005 which states on page 10 "The read-write memory space is only 1K. The real addresses for the RAM are 7000-73FF. The RAM space addresses available in memory for your ColecoVision projects are 7000-73B8. The stack pointer is initialised at 73B9 (firsts instructions in BIOS) but the stack really started at 73B8, 73B7, 73B6, etc. If you need more RAM space, you can use the video memory."


Hope this helps.

ColecoVision ROM Update Project - Commercial Releases (1982-198x) - v2.2.pdf

Link to comment
Share on other sites

I stand corrected then.


From my understanding is that you provide the stack address, the work buffers, the controller buffers ect....So they could be anywhere.


However if the bulletin says $7000 that's what it says.

All my testing has been on Colecovision emulators and a real ADAM.
Being as the unexpanded ADAM has physical memory up to 64k I suspect my roms will work even if I use $5000


I am glad we are working all of this out.


Edited by Captain Cozmos
Link to comment
Share on other sites

It's just a convention. The RAM exists from $6000 - $7FFF, but in that 8k range there is only 1k of RAM, and it repeats over and over. Some of the address bits are ignored, and this is how the mirroring happens (and this is a very normal thing in hardware). Coleco decided to document the RAM at $7000 as a convention, and it is usually best to follow the convention for maximum compatibility, because that is an assumption that would be made going forward.


To the CV hardware, there is literally no difference between $6000 and $7000. Think of it in terms of the hardware. Your address lines are the actual bits in the address:

Address: 6000 = 0110 0000 0000 0000
         7000 = 0111 0000 0000 0000

Wiring:         dddx xx11 1111 1111

d = decode bits, used by the circuit that decides what part of memory to access (011 = RAM)
x = not attached to RAM, ie: don't care
1 = used by the RAM chip to determine memory address

Because of the "don't care" bits, the RAM chip is at $6000. It's also at $6400, and $6800, and $6C00, and $7000, and $7400, and $7800, and $7C00. These are all 100% identical ways to access it. The chip itself only gets the bits I marked as '1' in the Wiring, so it has no idea what address it's actually responding to, except that 1k space.


On the Adam, all 8k is present, so there are no "don't care" bits to this RAM space.


As for "why" this mirroring exists - it's mostly simplicity/cost. The ColecoVision uses a single chip to map those three 'decode bits' to a space - giving it 8 different sections of memory. To decode with further accuracy, you need another chip, but everything works fine if you don't need it. There's no reason to add more circuitry just to make unused sections of the memory map do nothing - people aren't supposed to use them anyway. ;)

ColecoVision address decode:

000 - $0000 - BIOS ROM
001 - $2000 - normally unused on CV
010 - $4000 - normally unused on CV
011 - $6000 - RAM (1k on CV)
100 - $8000 - cartridge ROM select 0
101 - $A000 - cartridge ROM select 1
110 - $C000 - cartridge ROM select 2
111 - $E000 - cartridge ROM select 3

This also shows why there are four chip select pins on the cartridge port - they chose to expose the four that they had, rather than add another chip to combine them into just one. ;)


  • Like 1
Link to comment
Share on other sites

9 hours ago, Tursi said:

For what it's worth, the port I/O has a similar mapping scheme, and many of the ports mirror in their space too ;)


For the official record is it at $6000 or $7000



The programmer for GearColeco says $6000 because this is a multiple system emulator of that style with the ports changed for the Colecovision.


In one of his emails he explained that $6000 was where it is mapped on all of these similar systems so I would like to think that he did the research on the Colecovision but did not expect that Coleco were a bunch of cheap bastards when it boiled down to brass tacks.


ADAM could have been so much more if it were not for that addon mentality.

I have plenty of extra space on in VRAM but it is bottle necked by an NMI and port transfers and if I don't use the BIOS I get a whopping whole 1k.


What I have learned from working on Haunted House that the Atari 2600 may have blocky graphics but it was superior. (don't shoot me)

Power at the controller ports, better color scheme, bit plane graphics.

Link to comment
Share on other sites

For the official record is it at $6000 or $7000


Neither. And both. This is just how hardware works. Because the address bits for the mask $1C00 are literally not hooked up, they are not a part of the address decode. They are "don't care", and that's actually the term for it. However, Coleco said to use $7000 in their documentation, so that is the "technically right" answer. But since the system didn't evolve (beyond the Adam), it doesn't really matter which one you choose to use. It is equally correct to say the RAM is at $6C00 - it just looks weird to us humans. That said, $6000 is the base address of the decode. I'm not sure why Coleco decided to promote $7000 instead.


Texas Instruments did a similar thing with the TI-99/4A. The machine has 256 bytes of RAM mapped in the range from $8000 to $83FF (a 1k range, so it repeats 4 times). TI told people to use $8300, and not $8000 (or $8100 or $8200), as the base of RAM. Again, both are equivalent, so I don't know the reasoning.


Emulator authors are not concerned as much with the documentation, they need to consider the actual hardware. So in GearColeco, the RAM will respond at all of those addresses as well. If it didn't, software wouldn't work.


The NMI can be controlled. People just refuse to do it. I manage the NMI in Mario Bros, Mr Chin, and Super Space Acer just fine. I also helped with the interrupt handler in Tank Mission to tame the NMI. I'm not saying it's trivial, mind you. But if you keep it in mind you can control it.


As for the 2600, there are certainly features to be jealous of next to the 9918A. But at the same time, you don't have to cycle count or spend any CPU time to display a picture. Those were exciting times, as we were learning how computers should work - so they were all a little different. 

Edited by Tursi
Link to comment
Share on other sites

Funny because I was toying with some ADAM ram just to display a boot picture and there is literally an ocean of ram.

It was just pick a spot which is crazy.

The things about modern computers is that they have their own memory management while when you play around at this low of level it's crazy what you can get away with.

Link to comment
Share on other sites

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.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...