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


Unable to debug with ST-LinkV2-1

Hi,

My guess is that (as farlane pointed out below - sorry for jump) is a USB HW / WinUSB library problem. In your log, function stlink_usb_open() fails.

‘’Debug: 258 156 stlink_usb.c:1602 stlink_usb_open(): stlink_usb_open
‘’Debug: 259 156 stlink_usb.c:1619 stlink_usb_open(): transport: 1 vid: 0x0483 pid: 0x374b serial:
Error: 260 343 stlink_usb.c:1632 stlink_usb_open(): open failed

My understanding is that OpenOCD application try to connect using USB to the SWD debug probe but the application has no response from HW side.

What you can do:
Check again to have a good USB cable - I can see the same error when there is no target board attached.
Check jumpers on target board, if you have any, to be in correct position.

Check to have the latest firmware on ST-LINK using STM32 ST-Link Utility

I use the latest ST-LINK drivers from ST, maybe could help to uninstall the current drivers and then install latest ST divers. On my computer I run 3 times uninstall on STLink and only then the device became unknown in Device Manager.
Now I have this drivers: STSW-LINK009 link:http://www.st.com/web/en/catalog/tools/PF251168Question
Zadig tool reports the library version: WinUSB (v1.1.0.0)

Check this forum, there are few threads related to openocd.

Anyway, after I have done all this things still I was not able to connect to target board.
On my system (Asus X200LA) OpenOCD DOES WORK ONLY IF I completely remove from Device Manager
Ralink_MT6750_Bluetooth_01.

Attached is a description of my problem (3 pages).

If you can, check on another machine with different configuration the same setup. After I have seen this problem only on my pc, I use a virtual machine - Ubuntu and I added USB devices one by one into the WM and after each one verify that openocd still works (command line) until I find which device causes the problem.

Also you can check README.Windows file from OpenOCD (openocd.org). There are some hints related to USB adapters and libraries (but I was not able to follow all instructions and some of them are to “extreme” - see IgnoreHWSerNum).

Good luck