Newbie trouble. Debug my own board via ST-LINK-V2 in Discovery
Hello, there!
I use stm32l-discovery (with st-link/v2) with my own board. I connect via SWD (SWIO SWCLK) chip STM32F100C4T6B.
I generate first project from STM32CubeMX.
In Ac6 set in debug options my ST-LINK/V2.
Build is normal. I have a .elf file
In code navigator set breakpoint after main function in neverend while part.
When I try to debug, i get error (attach1) and next console output:
------------------------
Info : STM32F100C4Tx.cpu: hardware has 6 breakpoints, 4 watchpoints
Info : accepting ‘gdb’ connection on tcp/3333
Error: timed out while waiting for target halted
TARGET: STM32F100C4Tx.cpu - Not halted
in procedure ‘reset’
in procedure ‘ocd_bouncer’
Info : device id = 0x10016420
Info : flash size = 32kbytes
Error: timed out while waiting for target halted
TARGET: STM32F100C4Tx.cpu - Not halted
in procedure ‘reset’
in procedure ‘ocd_bouncer’
Error: timed out while waiting for target halted
TARGET: STM32F100C4Tx.cpu - Not halted
in procedure ‘reset’
in procedure ‘ocd_bouncer’
Error: Target not halted
Error: failed erasing sectors 0 to 3
Error: flash_erase returned -304
Info : dropped ‘gdb’ connection
------------------------------
What i do wrong?
How I can start debug from main function?
OpenSUSE 42.2 x64
System Workbench for STM32 - OpenOCD (for Linux 64bits) Version: 1.13.2.201703061529
STM32L-DISCOVERY with own connected board via SWD (no reset use)