Marek Buczkowski

MC9S08GT16 - problems with entering stop mode

Discussion created by Marek Buczkowski on Jun 27, 2007
Latest reply on Nov 28, 2007 by Luca Nogarotto
Hi,
I am trying to put microcontroller to stop mode 3 using this code:
/* register initialization */
  SOPT = 0x73;                                  
  SPMSC1 = 0x1C;                                      
  SPMSC2 = 0x00;                                      
  ICGC1 = 0x3C;                                      
  ICGC2 = 0x7C;
...
...
MCUInit();
Main(){
...
...
asm STOP
...
}
The problem is that the microcontroller doesn't enter stop mode. It executes the instruction asm STOP and goes to the next line of code, continuing normal work.
What do I do wrong? How should entering (and leaving) stop mode look like?
Please help,
- Marigold

Outcomes