cancel
Showing results for 
Search instead for 
Did you mean: 

NUCLEO-WBA65RI Standby current higher than expected

JPortilha
Associate III

Title edited to clarify that this refers to a NUCLEO-WBA65RI board.


Hello, 

I am currently using STM32WBA65RI with Standby mode. According to datasheet, this mode should be able to reach 120nA current consumption with the 16 GPIO wake-up pins (RTC disabled). However running the Standby example and shutting down the RTC I am still getting 3uA of current consumption. What can I do to decrease the current consumption up to the nanoA?

Best regards.

14 REPLIES 14
Andrew Neil
Super User

Please give full details of your test setup - schematic, code, etc.

See: How to write your question to maximize your chances to find a solution

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.
JPortilha
Associate III

Hello,

I am using the STM32WBA65RI Dev Kit. For current measurements, I am powering the board with an external supply that includes current measurement capability, connected directly to pin 1 of JP2. The JP4 jumper is removed.

According to the reference manual (Table 54), there are expected current consumption values for Standby mode (with RTC enabled and IWDG disabled).

I performed four tests with the following configurations:

  • RTC clocked by LSI and LSI/128
  • ULPMEN = 1
  • VDD = 1.8 V and 3.3 V

However, my measured current is consistently higher than the specified values:

  • LSI/128, 1.8 V → Expected: 210 nA, Measured: 658 nA
  • LSI/128, 3.3 V → Expected: 510 nA, Measured: 989 nA
  • LSI, 1.8 V → Expected: 330 nA, Measured: 835 nA
  • LSI, 3.3 V → Expected: 790 nA, Measured: 849 nA

My code is based on the ST example “Standby with RTC”, with the addition of enabling the ULPMEN bit in the PWR_CR1 register.

 

int main(void)
{
  HAL_Init();
  SystemClock_Config();
  MX_GPIO_Init();
  MX_ICACHE_Init();
  MX_RTC_Init();

  SystemPower_Config();
  CLEAR_BIT(DBGMCU->SCR, DBGMCU_SCR_DBG_STANDBY);
 /* Check and handle if the system was resumed from StandBy mode */
  if(__HAL_PWR_GET_FLAG(PWR_FLAG_SBF) != RESET)
  {
    /* Clear Standby flag */
    __HAL_PWR_CLEAR_FLAG(PWR_FLAG_SBF);
  }

  SET_BIT(PWR->CR1, PWR_CR1_ULPMEN);

  /* Insert 5 seconds delay */
  HAL_Delay(5000);
  /* Enable wakeup line 7 for RTC */
  HAL_PWR_EnableWakeUpPin(PWR_WAKEUP_PIN7_HIGH_3);
  
  HAL_RTCEx_DeactivateWakeUpTimer(&hrtc);
  /* Clear all related wakeup flags */
  __HAL_PWR_CLEAR_FLAG(PWR_WAKEUP_ALL_FLAG);
  /* Re-enable wakeup source */
  if (HAL_RTCEx_SetWakeUpTimer_IT(&hrtc, 0xFFFF, RTC_WAKEUPCLOCK_RTCCLK_DIV16, 0) != HAL_OK)
  {
    Error_Handler();
  }
  /* Enter the Standby mode */
  HAL_PWR_EnterSTANDBYMode();

 Also, my goal was to sleep for 1 minute, and then wake-up and do BLE advertise for 10 seconds. And so on. How can I integrate the BLE stack here to accomplish this?

Best regards.


@JPortilha wrote:

I am using the STM32WBA65RI Dev Kit. .


Which one - NUCLEO-WBA65RI or STM32WBA65I-DK1 ?

 

You need to carefully check the schematics for all potential sources of leakage - in particular, connections to the ST-Link.

Your difference is on the order of only 400nA - it really doesn't take much leakage at all to make that !

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.

I am using the NUCLEO-WBA65RI. According this this image, I am powering the MCU directly so the ST-Link below should be totally disconnected (I assume)

image.pngAlso, do you have any insights on how to integrate BLE advertise with this standby mode?


@JPortilha wrote:

According this this image, I am powering the MCU directly so the ST-Link below should be totally disconnected (I assume)


I think not: The ST-Link is still connected - just not powered.

Again, check the schematics to be sure.

 


@JPortilha wrote:

do you have any insights on how to integrate BLE advertise with this standby mode?


That's a separate question - please start a separate thread for that.

 

PS:

New thread: STM32WBA65RI BLE Advertise with Standby Mode

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.
JPortilha
Associate III

From the schematics analysis I could not figure out any point to where the current could be leaking. Can it be a software problem? Are the results presented on the datasheet accurate enough?

BR.

What about all these connections (from the User Manual):

AndrewNeil_0-1775732956487.png

https://www.st.com/resource/en/user_manual/um3448-stm32wba-nucleo64-board-mb1801-and-mb2130-stmicroelectronics.pdf#page=8

 

Again, it's only tiny amounts of current you're talking about!

 

Maybe try removing the MCU RF board (MB2130) from the mezzanine board (MB1801) ?

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.

Hello, I have removed the MCU board (MB2130), and I am powering up via CN4 pins. I have shunted the necessary solder bridges underneath the board I got these results while in stanby mode.

image (1).pngI can´t figure out what are those negatives spikes. The average value should be around the nano amps scale, but again not the 330nA at 1.8V specified in the datasheet.

BR

I don't know.

What are you measuring with?

A schematic and some good, clear photos would help to fully describe the setup.

Is the chip waking up periodically - something just under 1s ?

What is the average current between the spikes?

Remember that the datasheet figure is purely internal to the chip, so you will never achieve that in practice:  there will always be some leakage due to external components - capacitors, etc...

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.