2020-01-27 11:20 AM
I am using nucleo board with stm32l476rg for development. I found that under debugging mode, the program will reset itself and stlink will lose connection. I am not sure if the program causes the reset or the st-link causes the reset. Even I did not open the truestudio for debugging, the same thing happens and reset is observed.
I used a very simple program with only USB supported and running on an infinite loop waiting for usb commands. Even without any operations, the same thing will happen, which is about 5-10 mins. If I keep feeding usb commands, it seems OK.
Anyone can kindly give me some hints on this? I got stucked. Thank you so much.
Below is the logging:
STM32 device: flash programming successful 0x80313e8
Flash write completed in 0.220000 seconds, 2.592330kB/s
Enter STM32_AppReset() function
NVIC_DFSR_REG = 0x00000009
NVIC_CFGFSR_REG = 0x00000000
XPSR = 0x01000000
Reading 0x2 bytes of memory from addr 0x802acc8
Reading 0x2 bytes of memory from addr 0x802acc8
Reading 0x4 bytes of memory from addr 0x802ec50
Reading 0x4 bytes of memory from addr 0xe0042004
Reading 0x4 bytes of memory from addr 0x802ec50
Reading 0x2 bytes of memory from addr 0x802acc8
Reading 0x2 bytes of memory from addr 0x802acc8
Reading 0x2 bytes of memory from addr 0x802acc8
TraceCaptureStart and SWV event set to APP_TRUE
ST_LINK device status: RUN_MODE
ST_LINK device status: HALT_MODE
TraceCaptureStart and SWV event set to APP_FALSE
NVIC_DFSR_REG = 0x00000002
ST_LINK Halt Reason break point hit
Reading 0x4 bytes of memory from addr 0x802acc8
Reading 0x4 bytes of memory from addr 0xe000ed04
Reading 0x4 bytes of memory from addr 0xe000ed2c
Reading 0x4 bytes of memory from addr 0xe000ed28
Reading 0x4 bytes of memory from addr 0xe000ed38
Reading 0x4 bytes of memory from addr 0xe000ed34
Reading 0x4 bytes of memory from addr 0xe000ed04
Reading 0x4 bytes of memory from addr 0xe000ed2c
Reading 0x4 bytes of memory from addr 0xe000ed28
Reading 0x4 bytes of memory from addr 0xe000ed38
Reading 0x4 bytes of memory from addr 0xe000ed34
TraceCaptureStart and SWV event set to APP_TRUE
ST_LINK device status: RUN_MODE
ST_LINK device status: Failed to get status, Target not responding, retrying...
Target is not responding, retrying...
2020-01-27 11:24 AM
modification: even with command sending on usb, it still resets. Sorry for the wrong information.