UPI-41A/41AH/42/42AH USER’S MANUAL
DIS TCNTI
Disable Timer/Counter Interrupt
Opcode:
0 0 1 1
0 1 0 1
The timer/counter interrupt is disabled. Any pending timer interrupt request is cleared. The
interrupt sequence is not initiated by an overflow, but the timer flag is set and time accumula-
tion continues.
DJNZ Rr, address
Decrement Register and Test
Opcode:
1 1 1 0
1 r
2
r
1
r
0
#
a
7
a
6
a
5
a
4
a
3
a
2
a
1
a
0
This is a 2-cycle instruction. Register ‘r’ is decremented and tested for zero. If the register
contains all zeros, program control falls through to the next instruction. If the register con-
tents are not zero, control jumps to the specified address within the current page.
(Rr)
w
(Rr)
b
1
If R
i
0, then;
(PC
0–7
)
w
addr
Note:
A 10-bit address specification does not cause an error if the DJNZ instruction and the jump
target are on the same page. If the DJNZ instruction begins in location 255 of a page, it will
jump to a target address on the following page. Otherwise, it is limited to a jump within the
current page.
Example:
Increment values in data memory locations 50 – 54.
MOV R0,
Ý
50
;MOVE ‘50’ DEC TO ADDRESS
;REG 0
MOV R3,
Ý
05
;MOVE ‘5’ DEC TO COUNTER
;REG 3
INCRT: INC
@
R0
;INCREMENT CONTENTS OF
;LOCATION ADDRESSED BY
;REG 0
INC R0
;INCREMENT ADDRESS IN REG 0
DJNZ R3,INCRT
;DECREMENT REG 3ÐÐJUMP TO
;‘INCRT’ IF REG 3 NONZERO
NEXTÐÐ
;‘NEXT’ ROUTINE EXECUTED
;IF R3 IS ZERO
EN DMA
Enable DMA Handshake Lines
Opcode:
1 1 1 0
0 1 0 1
DMA handshaking is enabled using P
26
as DMA request (DRQ) and P
27
as DMA acknowl-
edge (DACK). The DACK lines forces CS and A
0
low internally and clears DRQ.
EN FLAGS
Enable Master Interrupts
Opcode:
1 1 1 1
0 1 0 1
The Output Buffer Full (OBF) and the Input Buffer Full (IBF) flags (IBF is inverted) are
routed to P
24
and P
25
. For proper operation, a ‘‘1’’ should be written to P
25
and P
24
before the
EN FLAGS instruction. A ‘‘0’’ written to P
24
or P
25
disables the pin.
36
Содержание 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 ...