Hi!
I'll be brief - I can't read a word from CRAM. Here's my test case:
; Write to colour 0,0
move.l #0xC0000000, vdp_control
move.w #0xABCD, vdp_data
; Read from colour 0,0
move.l #0x00000020, vdp_control
move.w vdp_data, d0
d0 contains 0x0ACC.
I've used TmEE's VDP Address Calculator to verify the command is correct, and double checked it against the bit table in that SEGA2F.DOC doing the rounds. The write works fine, I have palettes looking slick all over the show. All other VDP features are working reliably. Nothing in the VDP regs seems to affect CRAM so I'm not sure I can bodge anything like this up during initialisation.
It's not mandatory that I can do this, I'm trying to crossfade from one palette to another so keeping the current palette in a scratch buffer in RAM is no big deal, but I'd love to track down the cause.
I'll be brief - I can't read a word from CRAM. Here's my test case:
; Write to colour 0,0
move.l #0xC0000000, vdp_control
move.w #0xABCD, vdp_data
; Read from colour 0,0
move.l #0x00000020, vdp_control
move.w vdp_data, d0
d0 contains 0x0ACC.
I've used TmEE's VDP Address Calculator to verify the command is correct, and double checked it against the bit table in that SEGA2F.DOC doing the rounds. The write works fine, I have palettes looking slick all over the show. All other VDP features are working reliably. Nothing in the VDP regs seems to affect CRAM so I'm not sure I can bodge anything like this up during initialisation.
It's not mandatory that I can do this, I'm trying to crossfade from one palette to another so keeping the current palette in a scratch buffer in RAM is no big deal, but I'd love to track down the cause.