MCF52255: Low power wait mode vs Bwt

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

MCF52255: Low power wait mode vs Bwt

1,099 Views
SLSL
Contributor I

Hi,

 

I try to decrease current consumed by MCU (MCF52255).  I define two functions for that. First function turns MCU in low power Stop mode (deepest mode). Here is code for this action:

 

MCF_PMM_LPCR = 0
      | MCF_PMM_LPCR_LPMD_STOP          //Select stop mode 
      | MCF_PMM_LPCR_STPMD_ALL_DISABLED; // Highest stop level  
   
   MCF_PMM_LPICR = 0
      | MCF_PMM_LPICR_XLPM_IPL(5)  // Only level 6-7 exit from stop mode 
      | MCF_PMM_LPICR_ENBSTOP;      // Activate low power mode   
   
   asm( stop #0x2000);

 

The second function turns MCU in low power Wait mode. In this mode, I want CPU answers to interrupts. Here is code for this action:

 

MCF_PMM_LPCR = MCF_PMM_LPCR_LPMD_WAIT;          // Select wait mode 

 

MCF_PMM_LPICR = 0

| MCF_PMM_LPICR_XLPM_IPL(0)   // Any level can wake up MCU 

       | MCF_PMM_LPICR_ENBSTOP;      // Activate low power mode   

 

   asm( stop #0x2000);

 

 

If I use wait or stop function, when MCU is idle and FEC is not used (MCU does not wait for a FEC interrupt), that works well. When FEC is not used, external PHY is in Power Down mode.

 

There is a problem when I want use wait function when MCU is idle and FEC is used:  I don't know why, but Backup Watchdog Timer (BWT) resets MCU in this case (RSR register has 0x80 after MCU reset).

 

Do you have hints for me? 

 

Thanks, 

Steve

Labels (1)
0 Kudos
Reply
1 Reply

404 Views
SLSL
Contributor I

Other information

BWT counter is reset in RTC interrupt. RTC interrupt increment my SystemTick and it has frequency of 1000 Hz.

 

FEC interrupt seems cause problem to RTC interrupt... That's strange.

 

Steve

0 Kudos
Reply