Page 1 of 1

16 bit writes to 8 bit hardware registers

Posted: Sat Jan 01, 2011 12:42 pm
by Aphex
Hi,

Could anyone answer this trivial question for me?

Let's say the snes's cpu is in native mode and all registers and memory accesses are set to 16 bits. How does an 8 bit hardware register respond to a 16 bit write? For example.

Code: Select all

LDA #$AABB
STA $2100
Would $2100 now simply contain $AA?

P.S I apologise if this forum is strictly for Snes9x development discussion

Re: 16 bit writes to 8 bit hardware registers

Posted: Sun Jan 02, 2011 9:57 am
by BearOso
Aphex wrote:Hi,

Could anyone answer this trivial question for me?

Let's say the snes's cpu is in native mode and all registers and memory accesses are set to 16 bits. How does an 8 bit hardware register respond to a 16 bit write? For example.

Code: Select all

LDA #$AABB
STA $2100
Would $2100 now simply contain $AA?

P.S I apologise if this forum is strictly for Snes9x development discussion
I'm not a SNES programmer, but I'm fairly sure it writes across both $2100 and $2101. A better forum for this kind of topic would be byuu's ROM hacking board: http://board.byuu.org/viewforum.php?f=9

Re: 16 bit writes to 8 bit hardware registers

Posted: Sun Jan 02, 2011 11:35 am
by Aphex
Thanks, that makes sense actually. Also, byuu's forum does seem more relevent, thanks for the link.