OpCode Oddity? or bug in NX_800 manual/Dasm code?

Ltdannear

#1 ◈ 2025-01-15

I was trying to further my understanding of asm code and came across a difference between the Nx_800 book and the code dasm'ed by Andy's program.

In the book it shows
CLR A as opcode "FA" (DD = 1)
and
CLRB A as opcode "FB" (DD = 0)
In the dasm it seems to be different..

CLRB A shows as opcode "FA" (DD = 0)
CLR A shows as opcode "F9" (DD = 1)

I assume the dasm is correct and the book is wrong..? (Since the ROMs are working with this 'bug'..)

dip

#2 ◈ 2025-01-15

Re: OpCode Oddity? or bug in NX_800 manual/Dasm code?

For nX-8/500S Core :

opcode "FA" (DD=1) = CLR A

opcode "FB" (DD=0) = CLRB A

opcode "FAxx" (DD=0) = LB A,#xx

Ltdannear

#3 ◈ 2025-01-15

So, does the 66201, 207,etc.. not really follow the Nx8_500s core?

My 273_stock ASM:
Code:
                CLRB    A                      ; 0064 0 208 ??? FA


Code:
                CLR     A                      ; 022C 1 3F0 ??? F9


Note how it shows the opcode for clrb A is FA not FB
and CLR A opcode is F9 not FA
This is why I'm confused..