Login
Back to forumReply to this topicGo to last reply

Posted By

Haegar
on 2023-12-16
14:17:55
 change graphics memory

Hello folks,
sorry for the stupid question. How do I move the graphics memory again if I don't want multicolored graphics at $1800 but, for example, at $2000?
It's the register $ff12 for the bitmap and $ff14 for the color and screen memory, right?
Every time I try to adjust it, all I get is nonsense.

Posted By

gerliczer
on 2023-12-16
14:21:38
 Re: change graphics memory

Do you happen to move it to the upper half of the memory, as in above $8000?

Posted By

Csabo
on 2023-12-16
14:46:20
 Re: change graphics memory

It's a valid question happy To turn on multicolor graphics, you need to set 4 TED registers:

$20 bit of $FF06 has to be set (graphics mode)

$10 bit of $FF07 has to be set (multicolor)

The location of the bitmap can be any address on a $2000 boundary ($0000, $2000, $4000, $6000, etc.) This has to be written to $FF12. See the code below for values.

The location of the color map can be any address on a $0800 boundary. The high byte of this has to be written to $FF14.

Here's an actual working example, which turns on multicolor graphics at $8000, with the color map at $7800 (default Multi Botticelli file location):


lda #$3B ; turn graphics mode on
sta $FF06
;
lda $FF07 ; PAL/NTSC friendly
and #$40
ora #$18 ; $18 = multicolor, $08 = hires
sta $FF07
;
lda $FF12
and #$03 ; keep lowest 2 bits (sound)
ora #($8000) >> 10 ; $08 = $2000, $10 = $4000, etc.
sta $FF12
;
lda #$78 ; color map at $7800
sta $FF14


Hopefully this is clear enough happy

Posted By

gerliczer
on 2023-12-17
04:34:50
 Re: change graphics memory

AFAIR, there is somewhere yet another flag that should be checked, which controls whether the graphics data is taken from RAM or ROM. Colour and brightness map access will be controlled by the ROM paging status in the upper memory area, IIRC. I.e. if they are at $8800 they will work correctly only when ROM is paged out ($FF3F), otherwise ROM content will be used instead.

Posted By

Haegar
on 2023-12-17
08:17:58
 Re: change graphics memory

Great, thank you very much. Now I know where the error was, I remembered that the bitmap could be all $800.
Now it all makes more sense happy



Back to topReply to this topic


Copyright © Plus/4 World Team, 2001-2024