MCU mysterious freeze, no SWD access anymore.

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

MCU mysterious freeze, no SWD access anymore.

948 次查看
antoinezen
Contributor III

Context

We have from time to time our application that hangs shortly after the boot. We are not able to find what make the CPU freeze. The code is initializing peripherals at the time the CPU freeze. What I mean by freeze is that the program execution stops and we are not able to debug or access the CPU in anyway using SWD. (debug attach fails, access to RAM fails, etc..). Only a hard reboot can then exit this state (util, it locks again on the next boot). We can see a few prints over the LPUART before the CPU freeze. 

When a program image hand the CPU, this happens 100% of the boots. Changing a little in the image, such as adding "nop" instruction, can change a running image to a "freezing" image and vice-verca. This is really strange, and we have no explanation so far. Compiling on different PC or running the image on different target is consistent. 

The actual questions

What can case the SWD debug port to stop working ? What can cause the CPU to go in such a undetermined "freeze" state ?

What was done

  • Checked the errata. I don't think we are impacted by ERR006223,  ERR007265 that could cause CPU hang according the errata.
  • Checked the power rails voltage, power-up sequence timing and clock signals.
  • Tried to run the debugger until the CPU hang to have an idea of what part the code cause the CPU to hang, but it does not hang if the debugger is attached!
标签 (1)
0 项奖励
回复
1 回复

930 次查看
antoinezen
Contributor III

Do you think I might get an response from NXP's FEA soon or late ?

0 项奖励
回复