Are unusued bytes of palettes readable & writable?

Are you new to 6502, NES, or even programming in general? Post any of your questions here. Remember - the only dumb question is the question that remains unasked.

Moderator: Moderators

Post Reply
User avatar
Petruza
Posts: 311
Joined: Mon Dec 22, 2008 10:45 pm
Location: Argentina

Are unusued bytes of palettes readable & writable?

Post by Petruza » Sat Jun 05, 2010 4:09 pm

I've read that unused bytes of the palettes in VRAM, I.E. $3F04, $3F08, $3F0C and their mirrors, are general purpose 6bit registers.
So, they are just 6bit memory positions that can be read and written through $2006 / $2007 ?
Does anyone recall debugging / disassembling a game that used those registers?

User avatar
thefox
Posts: 3141
Joined: Mon Jan 03, 2005 10:36 am
Location: Tampere, Finland
Contact:

Post by thefox » Sat Jun 05, 2010 8:20 pm

I doubt anybody was THAT short on normal RAM.
Download STREEMERZ for NES from fauxgame.com! — Some other stuff I've done: fo.aspekt.fi

User avatar
Bregalad
Posts: 7951
Joined: Fri Nov 12, 2004 2:49 pm
Location: Chexbres, VD, Switzerland

Post by Bregalad » Sun Jun 06, 2010 1:01 am

Yes. The only way to display those color is to use forced VBlank and point at them with $2006.
Useless, lumbering half-wits don't scare us.

User avatar
Petruza
Posts: 311
Joined: Mon Dec 22, 2008 10:45 pm
Location: Argentina

Post by Petruza » Sun Jun 06, 2010 7:25 am

Bregalad wrote:Yes. The only way to display those color is to use forced VBlank and point at them with $2006.
Please explain further.
Colors? you mean use them as actual palette indexes?

tepples
Posts: 22054
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Post by tepples » Sun Jun 06, 2010 7:29 am

If you turn off rendering and point the VRAM address at a color, the color will display on the screen, even if it is one of the ordinarily unused alternate background colors (CGRAM $3F04, $3F08, $3F0C). This is the only way to put those three CGRAM entries through the video output.

User avatar
tokumaru
Posts: 11864
Joined: Sat Feb 12, 2005 9:43 pm
Location: Rio de Janeiro - Brazil

Post by tokumaru » Sun Jun 06, 2010 8:38 am

Petruza wrote:Please explain further.
Colors? you mean use them as actual palette indexes?
If the VRAM address register is pointing to the palette area while rendering is disabled, the color being pointed is shown on the screen, rather than color 0.

User avatar
blargg
Posts: 3715
Joined: Mon Sep 27, 2004 8:33 am
Location: Central Texas, USA
Contact:

Post by blargg » Sun Jun 06, 2010 9:27 am


Post Reply