Loading...
 

Zephyr project on STM32

   Zephyr Workbench, a VSCode extension to manage Zephyr on STM32.
It enables users to easily create, develop, and debug Zephyr applications.
Main features:
  • Install host dependencies.
  • Import toolchain and SDK.
  • Create, configure, build and manage apps.
  • Debug STM32.
You can directly download it from the VSCode marketplace
For more details, visit the Zephyr Workbench

System Workbench for STM32


OPENOCD Debug doesn't work, but on STM32 ST-LINK Software works

Hello,

I’m having the following issue. I’m using the STM32F030F4P6 microcontroller and ST-LINK V2 in SWD, and for some reason I’m not able to debug on OpenOCD. It works on STM32 ST-LINK Software. On OPENOCD console it show the following errors. What should I do ?

Open On-Chip Debugger 0.9.0-dev-00415-g2d4ae3f-dirty (2015-04-22-11:10)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
adapter speed: 1000 kHz
adapter_nsrst_delay: 100
none separate
srst_only separate srst_nogate srst_open_drain connect_deassert_srst
Info : Unable to match requested speed 1000 kHz, using 950 kHz
Info : Unable to match requested speed 1000 kHz, using 950 kHz
Info : clock speed 950 kHz
Info : STLINK v2 JTAG v23 API v2 SWIM v4 VID 0x0483 PID 0x3748
Info : using stlink api v2
Info : Target voltage: 3.227913
Error: init mode failed (unable to connect to the target)
in procedure ‘init’
in procedure ‘ocd_bouncer’

To make the debug work you can Erase the chip on the STM32 STLINK Software, it should work.

I had this problem. There was a configuration problem, I looked to the assert functions and it was to pointing to ‘0’ which I believe that resets the microcontroller. Then, I activated the FULL_ASSERT and then I could see what was wrong. In my case it was a GPIO configuration problem. I forgot to put the pulls (I thought that it was not necessary, it’s outputs) on the GPIO_InitTypeDef structure. After I did that, the debug was working.

You can try this solution, but don’t forget to Erase the chip before.


I have de same problem
I could connect with st link utility but now with system workbench to debug my application

this is the code

  1. include “stm32f0xx.h”



volatile uint32_t counter = 0;
int main( void ) {

HAL_Init();

GPIO_InitTypeDef GPIO_InitStruct;

/* GPIO Ports Clock Enable */
__GPIOA_CLK_ENABLE();

/*Configure GPIO pins : PAPin PAPin */
GPIO_InitStruct.Pin = GPIO_PIN_4;
GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP;
GPIO_InitStruct.Pull = GPIO_NOPULL;
HAL_GPIO_Init(GPIOA, &GPIO_InitStruct);

while(1)
{
HAL_GPIO_TogglePin(GPIOA, GPIO_PIN_4);
for(counter=0; counter


 

Newest Forum Posts

  1. Монтаж камина с грилем в Москве - установка и барбекю by KpddomErorb, 2025-05-10 18:28
  2. SPI on Nucleo_STMH533RE by royjamil, 2025-05-04 20:13
  3. SPI on Nucleo_STMH533RE by higginsa1, 2025-03-25 07:37
  4. SPI on Nucleo_STMH533RE by royjamil, 2025-03-23 11:31
  5. SPI on Nucleo_STMH533RE by higginsa1, 2025-03-23 09:33
  6. Configuring DMA for ADC in SW? by sam.hodgson, 2025-03-04 12:58
  7. Build a project in "release" mode by info@creosrl.it, 2025-02-20 18:12
  8. Build a project in "release" mode by info@creosrl.it, 2025-02-20 17:05
  9. Build a project in "release" mode by tang, 2025-02-20 10:36
  10. Build a project in "release" mode by info@creosrl.it, 2025-02-19 17:35

Last-Modified Blogs