Skip to main content
Aku
Associate II
April 27, 2023
Solved

STM32WB55 Random Core2 Hard Faults

  • April 27, 2023
  • 12 replies
  • 4493 views

Hi,

we've been testing STOP2 modes and faced random core2 crashes.

We use radio stack 1.15.0 Light

Crash data at 0x20030000: 0x1170fd0f   0x00000000   0x00000939   0x2003fa20

Any ideas?

This topic has been closed for replies.
Best answer by Aku

Issue was caused by incorrect clocking scheme caused by clock configuration condition race on deep sleep enter/exit. Happens only if 64 MHz PLL used for system clock.

Solution is kinda tricky: core1 is not allowed to perform switch to PLL, instead it must use SHCI_C2_SetSystemClock(available in radio stack 1.17.3 or later) to perform transition. Also if FreeRTOS used then IPCC SYS must be used in blocking mode since interrupts are not available at the moment of transition to stop mode.

12 replies

Remy ISSALYS
ST Technical Moderator
April 27, 2023

Hello,

When the hardfault occurs, can you check the value of FLASH_SR registrer?

Best Regards

Aku
AkuAuthor
Associate II
April 27, 2023

Hi Remi,

FLASH_SR were containing 0x0

We are using keystore in RAM, so core2 shouldn't write anything to flash.

Also no HSEMs were locked by core2

Remy ISSALYS
ST Technical Moderator
April 27, 2023

Hello,

How did you enter in stop2 low power mode? Are you using the low power manager used in STM32CubeWB package example? You can look BLE_HeartRate example that allow to reach stop2 low power mode.

Best Regards

Aku
AkuAuthor
Associate II
April 27, 2023
Remy ISSALYS
ST Technical Moderator
April 28, 2023

Hello,

After how long does the hard fault appear? Do you have a precise scenario that generate the hard fault?

Best Regards

Aku
AkuAuthor
Associate II
April 28, 2023

Some device crashes every couple hours, other can work days. We don't have exact way to reproduce it.

Remy ISSALYS
ST Technical Moderator
April 28, 2023

Hello,

Using your code to enter/exit in stop2 low power mode, I reproduce the hard fault on nucleo-wb55, issue is under investigation. I keep you inform as soon as possible.

Best Regards

Aku
AkuAuthor
Associate II
May 2, 2023

Awesome, waiting for results. Also can you link this to case 00178410 ?

Remy ISSALYS
ST Technical Moderator
May 11, 2023

Hello,

Issue is still under investigation to find the root causes.

Best Regards

Aku
AkuAuthor
Associate II
May 25, 2023

Any updates? This issues is severely affects our customers and we literally tried everything on our side. Most infuriating is that we can not restart core2 without restarting whole MCU.

Aku
AkuAuthorBest answer
Associate II
October 9, 2023

Issue was caused by incorrect clocking scheme caused by clock configuration condition race on deep sleep enter/exit. Happens only if 64 MHz PLL used for system clock.

Solution is kinda tricky: core1 is not allowed to perform switch to PLL, instead it must use SHCI_C2_SetSystemClock(available in radio stack 1.17.3 or later) to perform transition. Also if FreeRTOS used then IPCC SYS must be used in blocking mode since interrupts are not available at the moment of transition to stop mode.