Do the 420X registers only latch on the B param?
So if you set 4202 before 4203, it does not interfere with any ongoing multiplication?
So if you set 4202 before 4203, it does not interfere with any ongoing multiplication?
Code:
00/85B7 E2 10 mull_16_16_32result sep #$10 ;x,y 8 bit
00/85B9 A4 00 ldy j7E0000
00/85BB 8C 02 42 sty MultiplecandA
00/85BE A4 02 ldy a7E0002
00/85C0 8C 03 42 sty MultiplierB ;0*2 <start multiply
00/85C3 A4 01 ldy p7E0001
00/85C5 8C 02 42 sty MultiplecandA < modifies before 7 clocks??
00/85C8 A4 03 ldy p7E0003
00/85CA AD 16 42 lda ProdRemainLo < reads result
00/85CD 8C 03 42 sty MultiplierB ;1*3 < does this then latch both A and B and start the multiplication?
00/85D0 85 04 sta p7E0004 ;result 0*2
00/85D2 A4 02 ldy a7E0002
00/85D4 EA nop
00/85D5 AD 16 42 lda ProdRemainLo
00/85D8 8C 03 42 sty MultiplierB ;1*2
00/85DB 85 06 sta p7E0006 ;result 1*3
00/85DD A6 07 ldx p7E0007
00/85DF A5 05 lda p7E0005
00/85E1 18 clc
00/85E2 6D 16 42 adc ProdRemainLo
00/85E5 85 05 sta p7E0005 ;5 += 1*2
00/85E7 90 01 bcc b0085EA
00/85E9 E8 inx
00/85EA A4 00 b0085EA ldy j7E0000
00/85EC 8C 02 42 sty MultiplecandA
00/85EF A4 03 ldy p7E0003
00/85F1 8C 03 42 sty MultiplierB ;1*3
00/85F4 EA nop
00/85F5 A5 05 lda p7E0005
00/85F7 18 clc
00/85F8 6D 16 42 adc ProdRemainLo ;5+=1*3
00/85FB 85 05 sta p7E0005
00/85FD 90 01 bcc b008600
00/85FF E8 inx
00/8600 86 07 b008600 stx p7E0007
00/8602 C2 10 rep #$10 ;x,y 16 bit
00/8604 60 rts
00/85B9 A4 00 ldy j7E0000
00/85BB 8C 02 42 sty MultiplecandA
00/85BE A4 02 ldy a7E0002
00/85C0 8C 03 42 sty MultiplierB ;0*2 <start multiply
00/85C3 A4 01 ldy p7E0001
00/85C5 8C 02 42 sty MultiplecandA < modifies before 7 clocks??
00/85C8 A4 03 ldy p7E0003
00/85CA AD 16 42 lda ProdRemainLo < reads result
00/85CD 8C 03 42 sty MultiplierB ;1*3 < does this then latch both A and B and start the multiplication?
00/85D0 85 04 sta p7E0004 ;result 0*2
00/85D2 A4 02 ldy a7E0002
00/85D4 EA nop
00/85D5 AD 16 42 lda ProdRemainLo
00/85D8 8C 03 42 sty MultiplierB ;1*2
00/85DB 85 06 sta p7E0006 ;result 1*3
00/85DD A6 07 ldx p7E0007
00/85DF A5 05 lda p7E0005
00/85E1 18 clc
00/85E2 6D 16 42 adc ProdRemainLo
00/85E5 85 05 sta p7E0005 ;5 += 1*2
00/85E7 90 01 bcc b0085EA
00/85E9 E8 inx
00/85EA A4 00 b0085EA ldy j7E0000
00/85EC 8C 02 42 sty MultiplecandA
00/85EF A4 03 ldy p7E0003
00/85F1 8C 03 42 sty MultiplierB ;1*3
00/85F4 EA nop
00/85F5 A5 05 lda p7E0005
00/85F7 18 clc
00/85F8 6D 16 42 adc ProdRemainLo ;5+=1*3
00/85FB 85 05 sta p7E0005
00/85FD 90 01 bcc b008600
00/85FF E8 inx
00/8600 86 07 b008600 stx p7E0007
00/8602 C2 10 rep #$10 ;x,y 16 bit
00/8604 60 rts