
C8051F040/1/2/3/4/5/6/7
Rev. 1.5 143
SFR Definition 12.3. SFR Next Register: SFRNEXT
SFR Definition 12.4. SFR Last Register: SFRLAST
Bits7-0: SFR page context is retained upon interrupts/return from interrupts in a 3 byte SFR Page
Stack: SFRPAGE is the first entry, SFRNEXT is the second, and SFRLAST is third entry.
The SFRPAGE, SFRSTACK, and SFRLAST bytes may be used alter the context in the SFR
Page Stack. Only interrupts and returns from interrupt service routines push and pop the
SFR Page Stack. (See Section 12.2.6.2 and Section 12.2.6.3 for further information.)
Write:
Sets the SFR Page contained in the second byte of the SFR Stack. This will cause the
SFRPAGE SFR to have this SFR page value upon a return from interrupt.
Read:
Returns the value of the SFR page contained in the second byte of the SFR stack. This is
the value that will go to the SFR Page register upon a return from interrupt.
R/W R/W R/W R/W R/W R/W R/W R/W Reset Value
00000000
Bit7 Bit6 Bit5 Bit4 Bit3 Bit2 Bit1 Bit0
SFR Address:
SFR Page:
0x85
All Pages
Bits7-0: SFR page context is retained upon interrupts/return from interrupts in a 3 byte SFR Page
Stack: SFRPAGE is the first entry, SFRNEXT is the second, and SFRLAST is the third
entry. The SFR stack bytes may be used alter the context in the SFR Page Stack, and will
not cause the stack to ‘push’ or ‘pop’. Only interrupts and returns from the interrupt service
routine push and pop the SFR Page Stack.
Write:
Sets the SFR Page in the last entry of the SFR Stack. This will cause the SFRNEXT SFR to
have this SFR page value upon a return from interrupt.
Read:
Returns the value of the SFR page contained in the last entry of the SFR stack.
R/W R/W R/W R/W R/W R/W R/W R/W Reset Value
00000000
Bit7 Bit6 Bit5 Bit4 Bit3 Bit2 Bit1 Bit0
SFR Address:
SFR Page:
0x86
All Pages