Uli Kretzschmar

MCF51QE128 - Low Power Modes - stop4, stop3

Discussion created by Uli Kretzschmar on Nov 8, 2007
Latest reply on Mar 30, 2010 by Leonardo Gabrielli
Hi,

I am pretty new to the QE128. Right now I am wondering, if there are some code examples somewhere in the net. I only found some examples in this document here (http://www.freescale.com/files/microcontrollers/doc/user_guide/QE128QRUG.pdf?fsrch=1) but nothing to the low-power modes.

How can I put the CPU to stop4 mode? Right now I am doing all my work in ISR's and the CPU is in a "while(1)" loop. Now I want to put it to stop4 or even stop3 if possible.

But how does it work? I tried the following code for stop4:
  SPMSC2 &= ~ 0x80;  // LPR
  SPMSC2 &= ~ 0x01;  // PPDC;
  asm {  mov3q #4,d0; bclr.b d0,SOPT1; stop #0x2000; }
but after that my ISR's are not executed any longer...

Does somebody have any idea what the reason could be?

Ciao,
Uli

Outcomes