21.07.2015 Views

M16C User Manual.pdf

M16C User Manual.pdf

M16C User Manual.pdf

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Power ControlMitsubishi microcomputers<strong>M16C</strong> / 62 GroupSINGLE-CHIP 16-BIT CMOS MICROCOMPUTER2.14.2 Stop Mode Set-UpSettings and operation for entering stop mode are described here.Operation(1) Enables the interrupt used for returning from stop mode.(2) Sets the interrupt enable flag (I flag) to “1”.(3) Clearing the protection and setting all clock stop control bit to “1” stops oscillation and causesthe processor to go into stop mode.(1) Setting interrupt to cancel stop modeInterrupt control registerTBiIC(i=3 to 5) [Address 004516 to 004716]b7BCNIC [Address 004A16]KUPIC [Address 004D16]SiTIC(i=0 to 2) [Address 005116, 005316, 004F16]SiRIC(i=0 to 2) [Address 005216, 005416, 005016]TAiIC(i=0 to 4) [Address 005516 to 005916]TBiIC(i=0 to 2) [Address 005A16 to 005C16]b0b7Interrupt priority level select bitMake sure that the interrupt prioritylevel of the interrupt which is used tocancel the wait mode is higher thanthe processor interrupt priority(IPL) ofthe routine where the WAITinstruction is executed.INTiIC(i=3) [Address 004416]SiIC/INTjIC(i=4, 3) [Address 004816, 004916](j=3, 4) [Address 004816, 004916]INTiIC(i=0 to 2) [Address 005D16 to 005F16]b00Interrupt priority level select bitMake sure that the interrupt priority level of theinterrupt which is used to cancel the wait mode ishigher than the processor interrupt priority(IPL) ofthe routine where the WAIT instruction is executed.Reserved bitMust be set to “0”(2) Interrupt enable flag (I flag) “1”(3) Canceling protectb7b01Protect register [Address 000A16]PRCREnables writing to system clock control registers 0 and 1(addresses 000616 and 000716)1 : Write-enabled(3) Setting operation clock after returning from stop mode(When operating with XCIN after returning)(When operating with XIN after returning)b7b0 System clock control register0 0[Address 000616] CM0Main clock (XIN-XOUT) stop bitOnSystem clock select bitXIN, XOUTAs this register becomes setting mentioned above whenoperating with XIN (count source of BCLK is XIN),the user does not need to set it again.b71 1b0 System clock control register 0[Address 000616] CM0Port XC select bitXCIN-XCOUT generationSystem clock select bitXCIN, XCOUTAs this register becomes setting mentioned above when operating with XCIN(count source of BCLK is XCIN), the user does not need to set it again.When operating with XIN, set port Xc select bit to “1” before setting system clockselect bit to “1”. The both bits cannot be set at the same time.(3) All clocks off (stop mode)b7b00 0 0 0 1System clock control register [Address 000716]CM1All clock stop control bit1 : All clocks off (stop mode)Reserved bitMust be set to “0”All clocks off (stop mode)Figure 2.14.5. Example of stop mode set-up443

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!