cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F401 stop mode

matas
Associate II
Posted on September 03, 2015 at 17:18

Hey, I have encountered a interesting error. I have made a logger and to save power it goes to stop mode (~6-7ms), while the sensor is converting the results and to stand by mode (1-2s) till the next measurement. The datasheet says that while in stop mode the consumption should be ~40uA and in standby ~2-4uA. Now here is the question in standby mode the consumption is close to zero, while in stop mode it is ~20mA, so why? If the circuitry would be wrong the logger should always consume 20mA. The main code part looks like this:

  RTC_Config();

  PWR_EnterSTOPMode(PWR_LowPowerRegulator_ON, PWR_STOPEntry_WFI);

    

  

   RCC_APB1PeriphClockCmd(RCC_APB1Periph_PWR, ENABLE);

  

  /* Allow access to Backup */

   

  PWR_BackupAccessCmd(ENABLE);

  

  RTC_WakeUpCmd(DISABLE);

        

  SYSCLKConfig_STOP();

  GPIO_ResetBits(GPIOB, GPIO_Pin_14);

 

  

  PWR_ClearFlag(PWR_FLAG_SB | PWR_FLAG_WU);

  RTC_WaitForSynchro();

  RTC_ClearFlag(RTC_FLAG_WUTF);

  jumperTime = 1020;

  

  RTC_SetWakeUpCounter(jumperTime); 

  RTC_WakeUpCmd(ENABLE);

      

  PWR_EnterSTANDBYMode();

on each wake up it initializeses the RTC settings, and after Stop mode just changes the sleep duration. Have any of you encountered this?
1 REPLY 1
Posted on September 05, 2015 at 14:26

How do you measure the current? Can't this be the consequence of the processor running at full throttle before and after the 5-6ms stop period? Don't you have the debugger connected?

JW