2022-01-27 03:59 AM
Hi All,
I have a start up problem with the STM32L562QEI6.
While using the STM32CubeIDE debugger, the code runs fine but without the ST-LINK/V2 connected, the board remains "dead" after applying the power supply.
When I manually pull the nRST pin down before applying 3V3 and then release it, the board remains "dead". If I then pull it down a second time and release it, the board starts as expected.
So it looks like the first reset puts it in some (boot?) mode in which my code is not executed.
Some facts:
The current board is a migration from a previous version which is exactly the same except for the processor which used to be an STM32L433CCU6. All equivalent pins are connected in the same way.
With the 'L433' variant, we never did have any startup problem.
The only two differences are :
Both variants use the STM32 HAL drivers.
As you may understand, I'm out of ideas. It is probably a minor detail that I'm missing.....
Any help is highly appreciated !
Jeroen
2022-01-27 08:38 AM
I can even tie it directly to GND without any change. In fact, I already monitored this pin on the scope at the same time as Vdd and nRST and it is always at e few mV max.
2022-01-27 08:41 AM
then only debuger to problem can help seems as hardfault or other while 1 error
2022-01-28 02:35 AM
Solved this one. I had inadvertedly activated the Security Trustzone and ended up in a state that seems to disable programming via the IDE but not via the cube Programmer..
2022-04-04 02:29 AM
Problem solved. The source of the problem was the (windowed) watchdog. By disabling it, the firmware executes as expected.
I still have to find out what happens exactly since I need the watchdog to function. But that's another issue...