How to set sleep mode IN MC9S12XHZ512 controller?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to set sleep mode IN MC9S12XHZ512 controller?

1,233 Views
SARY
Contributor III

hi

    I want to build a function wjich should keep on running even in sleep mode.Can anyone tell me how to de that?

How to set the sleep mode and also will the clock will keep on oscillating in sleep mode?

SARY

Labels (1)
0 Kudos
Reply
3 Replies

707 Views
isionous
Contributor III

Looking at the datasheet, sleep mode seems to be specific to the CAN module.  Is that what you are talking about?  Or are you talking about wait mode or stop mode?

0 Kudos
Reply

707 Views
SARY
Contributor III

NO I am not talking about CAN module .Actually,I want to implement a function to calculate time ,which should keep on running when controller is in sleep mode or low power mode.

Even I didn't find any sleep mode in this controller.So which mode should I use and how to set that.

SARY

0 Kudos
Reply

707 Views
DPB
NXP Employee
NXP Employee

Hello

 

Pseudo STOP mode can be used with the RTI enabled to provide a time base within a low power mode.

This is described in chapter 7 of the Reference Manual S12XHZ-RM

 

Pseudo STOP mode is selected as opposed to STOP mode by setting the PSTP bit. Then when the CPU executes the STOP instruction, the device enters pseudo STOP mode instead of STOP mode. In pseudo STOP mode the oscillator continues operating.... 

 

Setting PSTP in the CLKSEL register ensures that the oscillator continues (pseudo STOP instead of STOP mode).

Setting PRE in the PLLCTL register enables the RTI in pseudo STOP

Register RTICTL is used to set the RTI rate.

RTIE in the register CRGINT enables the interrupt.

Ensure also that the CPU CCR S bit is clear for (pseudo) STOP mode entry.

 

DPB

.

0 Kudos
Reply