S12XDP512 not entering the Low Power WAIT mode??

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

S12XDP512 not entering the Low Power WAIT mode??

987 Views
RK1981
Contributor I
Hi All
 
The S12X controller is not entering the Low Power WAIT mode when i used the below code in C
 
This code is in the main function:
 
       _asm("sei");
       _asm("tfr ccr, a");
       _asm("anda #11101111b");
       _asm("tfr a, ccr");//clear i-bit
       _asm("nop");
       _asm("cli");
       _asm("wai");
 
cleared the I bit in CCR but the controller is not going to low power mode.
 
Can anyone help me out on how the S12X can be made to low power WAIT mode and How do i wake it up.
 
If its possible to post the C COde as well it very well appreciated.
 
Thanks
RK
Labels (1)
0 Kudos
0 Replies