SN8P1600
8-bit micro-controller
ONE ADDRESS SKIPPING
There are nine instructions (CMPRS, INCS, INCMS, DECS, DECMS, BTS0, BTS1, B0BTS0, B0BTS1) with one
address skipping function. If the result of these instructions is matched, the PC will add 2 steps to skip next instruction.
If the condition of bit test instruction is matched, the PC will add 2 steps to skip next instruction.
FC
C0STEP
; To skip, if Carry_flag = 1
; Else jump to C0STEP.
B0BTS1
JMP
.
C0STEP:
NOP
B0MOV
B0BTS0
JMP
A, BUF0
FZ
C1STEP
; Move BUF0 value to ACC.
; To skip, if Zero flag = 0.
; Else jump to C1STEP.
.
C1STEP:
NOP
If the ACC is equal to the immediate data or memory, the PC will add 2 steps to skip next instruction.
A, #12H
C0STEP
; To skip, if ACC = 12H.
; Else jump to C0STEP.
CMPRS
JMP
.
C0STEP:
NOP
If the result after increasing or decreasing by 1 is 0xFF or 0x00, the PC will add 2 steps to skip next
instruction.
INCS instruction:
BUF0
C0STEP
INCS
JMP
…
; Jump to C0STEP if ACC is not zero.
; Jump to C0STEP if BUF0 is not zero.
; Jump to C0STEP if ACC is not zero.
; Jump to C0STEP if BUF0 is not zero.
C0STEP:
NOP
INCMS instruction:
BUF0
C0STEP
INCMS
JMP
…
C0STEP:
NOP
DECS instruction:
BUF0
C0STEP
DECS
JMP
…
C0STEP:
NOP
DECMS instruction:
BUF0
C0STEP
DECMS
JMP
…
C0STEP:
NOP
SONiX TECHNOLOGY CO., LTD
Page 33
Revision 1.94