6F3B0253
Basic Hardware and Function 109
7. Instructions
Logical operations
FUN
No.
Name Expression Function Steps
Speed
(µs)
Page
048 AND
−[ A AND B → C ]−
Finds logical AND of A and B,
and stores it in C.
4 5.7 156
050 OR
−[ A OR B → C ]−
Finds logical OR of A and B,
and stores it in C.
4 5.7 157
052 Exclusive OR
−[ A EOR B → C ]−
Finds logical exclusive OR of A
and B, and stores it in C.
4 5.7 158
064 Bit test
−[ A TEST B ]−
Turns ON output if logical AND
of A and B is not 0.
3 5.0 163
Shift operations
FUN
No.
Name Expression Function Steps
Speed
(µs)
Page
068
1 bit shift right
−[ SHR1 A ]−
Shifts data of A 1 bit to the right
(LSB direction). The carry flag
changes according to the result.
2 6.8 164
069
1 bit shift left
−[ SHL1 A ]−
Shifts data of A 1 bit to the left
(MSB direction). The carry flag
changes according to the result.
2 6.8 165
070
n bit shift right
−[ A SHR n → B ]−
Shifts data of A n bits to the
right (LSB direction) and stores
the result in B. The carry flag
changes according to the result.
4 10.2 166
071
n bit shift left
−[ A SHL n → B ]−
Shifts data of A n bits to the left
(MSB direction) and stores the
result in B. The carry flag
changes according to the result.
4 10.2 167
074
Shift register
D SR Q
S (n)
E A
When shift input (S) comes ON,
shifts the data of specified shift
register 1 bit to the left, and
stores data input (D) state into
A. This operation is enabled
while enable input (E) is ON.
The carry flag changes
according to the result.
Shift register: n devices starting
with device A.
3
65.9 -
76.2
168
075
Bi-directional
shift register
D DSR Q
S (n)
E
L A
When shift input (S) comes ON,
shifts the data of specified shift
register 1 bit to the left or to the
right depending on direction
input (L). This operation is
enabled while enable input (E) is
ON. The carry flag changes
according to the result.
Shift register: n devices starting
with device A.
Direction: Left when L is ON,
right when L is OFF
3
69.0 -
79.3
170