UPI-41A/41AH/42/42AH USER’S MANUAL
OUTL Pp,A
Output Accumulator Data to Port 1 and 2
Opcode:
0 0 1 1
1 0 p
1
p
0
This is a 2-cycle instruction. Data residing in the accumulator is transferred (written) to port
‘p’ and latched.
(Pp)
w
(A)
P
e
1 – 2
Note:
Bits 0 – 1 of the opcode are used to represent PORT 1 and PORT 2. If you are coding in binary
rather than assembly language, the mapping is as follows:
Bits
Port
p
1
p
0
0
0
X
0
1
1
1
0
2
1
1
X
Example:
OUTLP; MOV A,R7
;MOVE REG 7 CONTENTS TO ACC
OUTL P2,A
;OUTPUT ACC CONTENTS TO PORT2
MOV A,R6
;MOVE REG 6 CONTENTS TO ACC
OUTL P1,A
;OUTPUT ACC CONTENTS TO PORT 1
RET
Return Without PSW Restore
Opcode:
1 0 0 0
0 0 1 1
This is a 2-cycle instruction. The stack pointer (PSW bits 0 – 2 is decremented. The program
counter is then restored from the stack. PSW bits 4 – 7 are not restored.
(SP)
w
(SP)
b
1
(PC)
w
((SP))
RETR
Return With PSW Restore
Opcode:
1 0 0 1
0 0 1 1
This is a 2-cycle instruction. The stack pointer is decremented. The program counter and bits
4 – 7 of the PSW are then restored from the stack. Note that RETR should be used to return
from an interrupt, but should not be used within the interrupt service routine as it signals the
end of an interrupt routine.
(SP)
w
(SP)
b
1
(PC)
w
((SP))
(PSW
4–7
)
w
((SP))
RL A
Rotate Left Without Carry
Opcode:
1 1 1 0
0 1 1 1
The contents of the accumulator are rotated left one bit. Bit 7 is rotated into the bit 0 position.
(A
n
a
1
)
w
(A
n
)
n
e
0 – 6
(A
0
)
w
(A
7
)
Example:
Assume accumulator contains 10110001.
RLNC: RL A
;NEW ACC CONTENTS ARE 01100011
47
Содержание UPI- 41A
Страница 1: ...October 1993 Microprocessor Peripherals UPI 41A 41AH 42 42AH User s Manual Order Number 231318 006 ...
Страница 4: ......
Страница 12: ...UPI 41A 41AH 42 42AH USER S MANUAL 231318 7 Figure 2 2 Pin Configuration 231318 8 Figure 2 3 Logic Symbol 8 ...
Страница 65: ...UPI 41A 41AH 42 42AH USER S MANUAL 231318 42 Figure 5 11 Distributed Processor System 61 ...