English
Language : 

45111 Datasheet, PDF (137/184 Pages) List of Unclassifed Manufacturers – 14-DAY MONEY BACK GUARANTEE
13 Appendix C: SX Instruction Set
NOT dest
Not dest
Command
1) NOT fr
2) NOT W
Words
1
1
Cycles
1 (4)
1 (4)
Affects
fr, Z
W, Z
Coding
0010 011f ffff NOT fr
1111 1111 1111 NOT w
Operation: dest is converted into its one’s complement value. Z will be set if the result was 0; otherwise, Z will be
cleared. The MOV W,/fr command is similar to #1, except the result is moved to W, and fr keeps its original
contents.
OR
dest, src
OR src into dest
1) OR
2) OR
3) OR
4) OR
5) OR
Command
fr, W
fr, #literal
fr1, fr2
W, fr
W, #literal
Words
1
2
2
1
1
Cycles
1 (4)
2 (8)
2 (8)
1 (4)
1 (4)
Affects
fr, Z
fr, W, Z
fr, W, Z
W, Z
W, Z
Coding
0001 001f ffff OR fr, W
1100 kkkk kkkk MOV W, #lit
0001 001f ffff OR fr, W
0010 000f ffff MOV W, fr2
0001 001f ffff OR fr, W
0001 000f ffff OR W, fr
1101 kkkk kkkk OR W, #lit
Operation: src is OR’d into dest. Z will be set if the result was 0; otherwise, Z will be cleared.
PAGE addr12
Set page select bits
Command
1) PAGE addr12
Words
1
Cycles
1 (4)
Affects
PAx
Coding
0000 0001 0fff PAGE addr
Operation: Writes upper address bits into status register in preparation for a jump or call across a page boundary.
On the SX20/28, address bits 10 and 9 are written into status register bits 6 and 5. On the SX48/52,
address bits 11 through 9 are written into status register bits 7 through 5. Status register bits 7 though 5
are also called PA2 through PA0.
RET
Return from subroutine
Command
1) RET
Words
1
Cycles
3 (8)
Affects
PC
Coding
0000 0000 1100 RET
Operation: The top stack value is moved into the program counter and execution proceeds with the instruction
following the most recent call instruction.
SX-Key/Blitz Development System Manual 2.0 • Parallax, Inc. • Page 137