2024-09-25 02:26 AM - edited 2024-09-25 02:28 AM
I am debugging an application for an STMF103RCTX Using STM32CubeIDE and an STLINK v2 debugger.
This is my usual combination of tools and my usual hookup.
I find that I can start a debug session and step into main() and even step over anything befoer HAL_Init(); but as soon as I hit that the begugger connection fails.
I've made a short video showing this issue:
My hookup from the STLINK to the device is as follows:
STLINK ---> DEVICE
Pin 2 VCC ---> VCC
Pin 4 GND ---> GND
Pin 7 TMS/SWDIO ---> PA13/TMS/SWDIO (46)
Pin 9 TCLK/SWCLK ---> PA14/TCLK/SWCLK (50)
Pin 15 --> RESET ---> nRST (7)
Any ideas? (The app runs perfectly when not trying to debug it)
Solved! Go to Solution.
2024-09-25 03:38 AM
Nevermind i found it. I started a new project with just serial debugging enabled, nothing else. I show the same code.
2024-09-25 04:05 AM
I was wondering why the pins were yellow? I did some testing. So it turns out that you must have manually set the pins, which it then turns yellow. But if you set it to Serial Wire it turns green.
2024-09-25 04:17 AM
@Karl Yamashita That's good to know. Thanks.