CHAPTER 3 FEATURES OF ARCHITECTURE AND MEMORY MAP
46 Users Manual U10676EJ3V0UM
Figure 3-4. Example of Using Register Banks
<Main program>
<Single interrupt> <Nesting of two
interrupts> ; RBE = 1
<Nesting of three
interrupts> ; RBE = 0
; RBE = 0
in vector table in vector table in vector table
PUSH BS
SEL
RB1
PUSH rp
RB = 2 RB = 0 RB = 1 RB = 0
RETI POP BS
RETI
POP rp
RETI
SET1 RBE
SEL RB2
If RBS is to be changed in the course of subroutine processing or interrupt servicing, it must be saved or restored
by using the PUSH or POP instruction.
RBE is set by using the SET1 or CLR1 instruction. RBS is set by using the SEL instruction.
Example SET1 RBE ; RBE 1
CLR1 RBE ; RBE 0
SEL RB0 ; RBS 0
SEL RB3 ; RBS 3
The general-purpose register area provided in the
µ
PD754244 can be used not only as 4-bit registers but also
as 8-bit register pairs. This feature allows the
µ
PD754244 to provide transfer, operation, comparison, and increment/
decrement instructions comparable to those of 8-bit microcontrollers and allows you to program using mainly general-
purpose registers.