Fujitsu MB90335 Series Hardware Manual page 177

16-bit microcontroller
Table of Contents

Advertisement

CHAPTER 6 LOW-POWER CONSUMPTION MODE
6.8 Precautions when Using Low-power Consumption Mode
■ Notes on Accessing the Low-Power Consumption Mode Control Register (LPMCR) to
Enter the Standby Mode
To access the low-power consumption mode control register (LPMCR) with assembler language
To set the low-power consumption mode control register (LPMCR) to enter the standby mode, use the
instruction listed in Table 6.3-2.
The low-power consumption mode transition instruction in Table 6.3-2 must always be followed by an array of
instructions highlighted by a line below.
MOV LPMCR,#H'XX
NOP
NOP
JMP $+3
MOV A,#H'10
The devices does not guarantee its operation after returning from the low-power consumption mode if you
place an array of instructions other than the one enclosed in the line.
To access the low-power consumption mode (LPMCR) with C language
To enter the standby mode using the low-power consumption mode control register (LPMCR), use one of
the following methods (1) to (3) to access the register:
(1) Specify the standby mode transition instruction as a function and insert two _wait_nop() built-in
functions after that instruction. If any interrupt other than the interrupt to return from the standby mode
can occur within the function, optimize the function during compilation to suppress the LINK and
UNLINK instructions from occurring.
Example: Watch mode or time-base timer mode transition function
(2) Define the standby mode transition instruction using _asm statements and insert two NOP and JMP
instructions after that instruction.
Example: Transition to sleep mode
(3) Define the standby mode transition instruction between #pragma asm and #pragma endasm and insert
two NOP and JMP instructions after that instruction.
156
Void enter_watch(){
IO_LPMCR_byte = 0x10
_wait_nop();
_wait_nop();
}
_asm(" MOV I: _IO_LPMCR,#H'58"); /* Set LPMCR SLP bit to "1" */
_asm(" NOP");
_asm(" NOP");
_asm(" JMP $+3");
Example: Transition to stop mode
#pragma asm
MOV I: _IO_LPMCR,#H'98
NOP
NOP
JMP $+3
#pragma endasm
FUJITSU MICROELECTRONICS LIMITED
; the low-power consumption mode transition instruction in Table 6.3-2
; jump to next instruction
; any instruction
/* Set LPMCR TMD bit to "0" */
/* Jump to next instruction */
/* Set LPMCR STP bit to "1" */
/* Jump to next instruction */
MB90335 Series
CM44-10137-6E

Advertisement

Table of Contents
loading

This manual is also suitable for:

F2mc-16lxMb90v330aMb90f337Mb90337

Table of Contents