cancel
Showing results for 
Search instead for 
Did you mean: 

Stop mode current with NUCLEO-32

LaurentLef
Associate II

Hi,

I am using the NUCLEO-32 STM32L011 kit and I want to put the MCU in stop mode to measure Idd. Everything seems to be going well but when I measure the current, this is 2.5µA versus 0.5µA announced in the datasheet when the stop mode is activated with the RTC active.

The measurement is performed on the JP1 connector therefore with a supply voltage of 3.3V.

I don't see what other components could consume this 2µA more, does anyone have an idea?

17 REPLIES 17
LaurentLef
Associate II

Thanks for this information.

Something bizarre: all the peripherals (Bor, PVD, ADC, and comparator) which use the VREFINT are off and yet the VREFINT_RDY_FLAG is at "1" in the SYSCFG_CFGR3 and PWR_CSR registers.

Does this mean that the Vrefint is active and therefore consumes 1.3µA in stop mode?

KDJEM.1
ST Employee

Hello @LaurentLef​,

It is mentioned in RM0377 the VREFINTRDYF reset value equal to 1 in the PWR_CSR register.

Make sure that the GPIOC is configurated in mode Analog.

Kaouthar

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

LaurentLef
Associate II

Hi Kaouthar,

In the PWR_CSR register, the reset value is "1" for the bit VREFINTRDYF, but in the SYSCFG_CFGR3 register, the reset value is "0" for the bit VREFINT_RDYF, so it's not easy to know.

I had forgotten the GPIOCs, thank you, it is corrected in analog mode but still an IDD = 2.5µA and therefore 2.2µA more.

Laurent.

KDJEM.1
ST Employee

Hello @LaurentLef​,

To minimize the power consumption, please try to add this code line before entering in STOP mode in your main.c.

SET_BIT(PWR->CR, PWR_CR_ULP);

Please let me know if the problem is solved.

Thank you

Kaouthar

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Thanks for your interest.

I had already enabled the ULP bit, so I disabled it to see if the consumption increased and the result is very strange.

Test 1: start in LP-RUN mode then switch to STOP mode with the ULP bit at "1": Idd=2.6µA

Test 2: start in LP-RUN mode then switch to STOP mode with the ULP bit at "0": Idd=2.6µA

Test 3: start in RUN mode then switch to STOP mode with the ULP bit at "1": Idd=2.6µA

Test 4: start in RUN mode then switch to STOP mode with the ULP bit at "0": Idd=2.6µA

==> The ULP bit seems to have no effect, whatever the previous RUN mode (RUN or LP-RUN, the consumption between these 2 active modes is different and consistent with the datasheet))

I tried to switch to STANDBY mode versus STOP mode, but the result is the same, always 2.6µA (2.595µA precisely), which is even more surprising since the STANDBY mode consumes about 0.1µA less than the STOP.

Laurent Lefevre

[edit: contact details removed by moderator]

KDJEM.1
ST Employee

Hello @LaurentLef​,

I have already tested the current consumption in stop mode with VREFINT off, and I find an Idd=0.45µA.

You can find in attached the main.c.

I hope this helps!

Kaouthar 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Hi and Thank you Kaouthar, the current consumption of your example on the Nucleo STM32L011 kit is indeed ~0.4µA as indicated in the technical documentation. I now need to understand what's different with my code and I'll come back to tell you.
Laurent Lefevre
LaurentLef
Associate II

Hi Kaouthar,

The consumption measured in STOP mode, without any other peripheral activated, is approximately 0.39µA.

If we add the validation of the LSI clock we go to about 0.92µA, or +0.53µA (slightly more than the max value given in the data sheet 0.521µA)

Then we add the RTC, we then go to about 1.15µA, i.e. +0.23µA (still a little more than the max value given in the data sheet 0.19µA)

Then we validate the wakeUp with the RTC "HAL_RTCEx_SetWakeUpTimer_IT()" we then go to about 52µA

We then disable the wakeup with the RTC "HAL_RTCEx_DeactivateWakeUpTimer()" to return to the 2.6µA measured during my previous tests.

Conclusion: If I switch to STOP mode with the programming of a WakeUp via the clocked RTC on the LSI then the current consumption is around 52µA which is more than operation in LP_RUN mode at 65KHz (IDD=18µA typ.)

Where is my mistake, does anyone see it?