cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L431KCU STM32Cube IDE with j-link needs power cycling after flash to run the program. Why?

TBone
Associate

Hi,

I'm using STM32L431KCU6 in a battery powered application running on custom hardware. The clock frequency is set to 72MHz after init, then it goes to stop mode and consumes less then 10uA. The battery is soldered to the PCBA.

As I flash the code to the MCU and removing the programming header it consumes about 10mA, which looks still running on 72MHz and not going to sleep. Otherwise the code looks running correctly. If I disconnect and reconnect the battery the consumption drops to 10uA as needed and the code is running correctly.

I tried to check every settings for the j-link but nothing helps.

Since in this application the battery is soldered to the board it looks problematic to cycle the power.

I'm just new to CubeIDE and mainly hw engineer, so it should be some banal mistake. I haven't seen such thing on other brand ARMs.

Anyone has any idea what to do?

Thanks,

T

3 REPLIES 3

Hello

A reset after programming, starts the program. No need to disconnect the battery

In JLink connector should exist the NRST pin

In Keil IDE to start the device after programming, is an option.

Thanks I tried it doesn't help.​

Seems that some data from backup used by new program for configurationare not valid.

Need to make some code called "factory settings" to be called some way not only after POR.