47
CHAPTER 4 INTERNAL CPU FUNCTIONS
PC12 PC11 PC10 PC9 PC8 PC7 PC6 PC5 PC4 PC3 PC2 PC1 PC0PC13
PC10 PC9 PC8 PC7 PC6 PC5 PC4 PC3 PC2 PC1 PC0PC11
PC11 PC10 PC9 PC8 PC7 PC6 PC5 PC4 PC3 PC2 PC1 PC0PC12
4.2 PROGRAM COUNTER (PC):
12 BITS (µPD750004)
13 BITS (µPD750006 AND µPD750008)
14 BITS (µPD75P0016)
The program counter is a binary counter which retains the address data of the program memory. The
program counter consists of 12 bits in the µPD750004 (see Figure 4-2(a)), 13 bits in the µPD750006 and
µPD750008 (see Figure 4-2(b)), and 14 bits in the µPD75P0016 (see Figure 4-2(c)).
Figure 4-2. Program Counter Organization
(a) µPD750004
(b) µPD750006 and µPD750008
(c) µPD75P0016
Usually, each time an instruction is executed, the program counter is automatically incremented according
to the number of bytes in the instruction.
When a branch instruction (BR, BRA, BRCB) is executed, immediate data indicating the branch destination
and the contents of a register pair are set in all or some bits of the program counter.
When a subroutine call instruction (CALL, CALLA, CALLF) is executed, or a vectored interrupt occurs, the
current contents of the program counter (already incremented return address for fetching the next instruction)
are saved in the stack memory (data memory indicated by the stack pointer), then the jump destination address
is loaded.
When a return instruction (RET, RETS, RETI) is executed, the contents of the stack memory are set in the
program counter.
When the RESET signal is issued, the program counter is initialized to the contents of the program memory
at addresses 000H and 001H. The program can be started from any address according to the contents.
µPD750004 :
PC11-PC8 <– (000H) 3-0, PC7-PC0 <– (001H) 7-0
µPD750006 and µPD750008 :
PC12-PC8 <– (000H) 4-0, PC7-PC0 <– (001H) 7-0
µPD75P0016 :
PC13-PC8 <– (000H) 5-0, PC7-PC0 <– (001H) 7-0