Using $0600 for an array...

Discuss technical or other issues relating to programming the Nintendo Entertainment System, Famicom, or compatible systems.

Moderator: Moderators

Post Reply
User avatar
Sivak
Posts: 316
Joined: Tue Jul 17, 2007 9:04 am
Location: Somewhere
Contact:

Using $0600 for an array...

Post by Sivak »

This may sound like a dumb question, but I wanted to confirm: In my Simon clone Siamond, I was previously using a simple variable in zero page of size 51 bytes for my array to hold the game's sequence (the game stopped at 50 colors).

Though I came up with the idea of maybe using some other memory and thought that since $0200 was used by the NSF and $0400 was my sprite DMA, that I could just use one of those other memory spots. I picked $0600 arbitrarily. It isn't used (that I know of) by anything else.

So my question is: Is this an okay thing to do? It seems to work fine, but I just wanted to make sure. Probably one of those over-paranoid scenarios.
tepples
Posts: 22345
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Post by tepples »

You can watch your existing code in FCE Ultra's memory viewer to make sure nothing is writing to it.
doynax
Posts: 162
Joined: Mon Nov 22, 2004 3:24 pm
Location: Sweden
Contact:

Re: Using $0600 for an array...

Post by doynax »

Just to be clear the NES has no operating system you can interfere with, or IO registers in the RAM area, or sections dedicated to any specific task aside from the 6502's zeropage and stack areas. Well, that and the OAM DMA has a 256-byte granularity but aside from that you're essentially care-free :)
Post Reply