COLOR=RESTORE

Par PingPong

Enlighted (4156)

Portrait de PingPong

14-07-2008, 20:26

Hi, i know that the color=restore command read palette from vram and feed to the VDP. However i do not remember the address from vram palette is taken. i need this info for screen modes 4-5

Anyone remember ?

!login ou Inscrivez-vous pour poster

Par Jipe

Paragon (1625)

Portrait de Jipe

14-07-2008, 20:55

screen 4 : 1E80H 1E9FH

screen 5 : 7680H 769fH

Par PingPong

Enlighted (4156)

Portrait de PingPong

15-07-2008, 00:35

screen 4 : 1E80H 1E9FH

screen 5 : 7680H 769fH

thx

Par ro

Scribe (5061)

Portrait de ro

15-07-2008, 09:33

in Basic there's also the BASE command, not? (which tells you where what is stored in Vram)

Par [D-Tail]

Ascended (8263)

Portrait de [D-Tail]

15-07-2008, 10:48

ro: I guess reading/writing the VDP registers is more like these guys -- in BASIC you can read VDP register values when needed, so it's easy to compute the location of the color table (SPAT - 512).

Par PingPong

Enlighted (4156)

Portrait de PingPong

15-07-2008, 19:44

ro: I guess reading/writing the VDP registers is more like these guys -- in BASIC you can read VDP register values when needed, so it's easy to compute the location of the color table (SPAT - 512).
D-tail. I'm not speaking about sprite att table but instead of the vram region where is stored the palette.
(I know the vdp store it's palette in registers, but there is also a vram region that hold this)

Par [D-Tail]

Ascended (8263)

Portrait de [D-Tail]

15-07-2008, 19:50

*slaps self*, yes, then the BASE commands would be a viable alternative Wink

Par flyguille

Prophet (3031)

Portrait de flyguille

15-07-2008, 23:02

the palette table is NOT stored in VRAM
it is on a table writable/readable on VDP registers....

The MSXBIOS has the default values of that table stored in ROM

Par NYYRIKKI

Enlighted (6093)

Portrait de NYYRIKKI

15-07-2008, 23:37

for I=4 to 8: ?"SCREEN";I;" Palette: #";HEX$(BASE(I*5+3)+128):next

Par k0ga

Expert (77)

Portrait de k0ga

16-07-2008, 08:35

the palette table is NOT stored in VRAM
it is on a table writable/readable on VDP registers....

The MSXBIOS has the default values of that table stored in ROM

flyguille, two things:

1º VDP palette registers are only writable, non readable.
2º MSX BIOS write a copy of palette in VRAM, so you can restore it with sc5 files (sc5 is only a vram dump) for example.