2023-05-06 08:35 AM
I have written code with two push buttons to control a set of LEDs, however every time I run the code it says target is not responding, not exactly sure what is wrong with my code.
Also I have tried other programs without pushbuttons and it uploads just fine. I have set PA14 and PA14 to GPIO_INPUT and to pull ups but that did not seem to fix the issue.
The code will be in a separate comment file.
Also I checked the hardware, pushbuttons work fine along with the LEDs.
2023-05-06 08:36 AM
2023-05-08 02:17 AM - edited 2023-11-20 06:14 AM
Hello @DRicc.2
First let me thank you for posting.
Are you able to connect to the target the you get the error while executing the code. Or does the error popup when you try to start a debug session.
Could you provide the debug log for analysis?
To do so, go to the debug configuration check the "log to file" option then specifies the path where to save the log.
KR,
Semer.
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2023-05-08 06:43 AM
It happens when I try to upload the code, it starts uploading and then never finishes with the same line repeating "target is not responding". I am using an STM32 Nucleo L476RG board, and will send the debug configuration file later tonight.
2023-05-08 08:01 AM
Avoid using the debug pins for buttons, remove.
Use Connect Under Reset options
Jumper BOOT0 HIGH to stop your code running if you need to do that to recover.
Recover board/part with STM32 Cube Programmer directly.
2023-05-12 07:15 PM
Not entirely sure where the reset options are, also tried to find the file output for the debug analysis, but cant find the menu you attached in the screen shot. I will try and use different pins instead to see if that changes anything. Also forgot to mention that it does upload in the sense that the first led will turn on at the top, but pushing the push buttons to turn on the other leds and turn off the ones in front doesn't work.
2023-05-13 07:38 AM