MITSUBISHI MICROCOMPUTERS
4280 Group
SINGLE-CHIP 4-BIT CMOS MICROCOMPUTER for INFRARED REMOTE CONTROL TRANSMITTERS
(8) Program counter (PC)
Program counter (PC) is used to specify a ROM address (page
and address). It determines a sequence in which instructions
stored in ROM are read. It is a binary counter that increments
the number of instruction bytes each time an instruction is
executed. However, the value changes to a specified address
when branch instructions, subroutine call instructions, return
instructions, or the table reference instruction (TABP p) is
executed.
Program counter (PC)
p3
p2
p1
p0
a6
a5
a4
a3
a
2
a1
a
0
PC
Specifying
page
H
PC
L
Specifying address
Program counter consists of PCH (most significant bit to bit 7)
which specifies to a ROM page and PCL (bits 6 to 0) which
specifies an address within a page. After it reaches the last
address (address 127) of a page, it specifies address 0 of the
next page (Figure 7).
Fig. 7 Program counter (PC) structure
Make sure that the PCH does not exceed after the last page of
the built-in ROM.
Data pointer (DP)
X1 X0 Y3 Y2 Y1 Y0
(9) Data pointer (DP)
Data pointer (DP) is used to specify a RAM address and
consists of registers X and Y. Register X specifies a file and
register Y specifies a RAM digit (Figure 8).
Register Y is also used to specify the port D bit position.
When using port D, set the port D bit position to register Y
certainly and execute the SD, RD, or SZD instruction (Figure
9).
Specifying
RAM digit
Register Y (4)
Specifying RAM file
Register X (2)
Fig. 8 Data pointer (DP) structure
Specifying bit position
Set
D7
D5
D0
1
0 1
1
0
Port D output latch
Register Y (4)
Fig. 9 SD instruction execution example
MITSUBISHI
ELECTRIC
8