Ubuntu, can't program using stlink mini v3

Hey everyone! I’m trying to set up a development env in ubuntu 22.04 I’ve managed to get everything to compile and I’m able to flash via usb. However, trying to flash via openocd gives me a very undescriptive message

openocd -s /usr/local/share/openocd/scripts -f interface/stlink.cfg -f target/stm32h7x.cfg \
	-c "program ./build/Blink.elf verify reset exit"
Open On-Chip Debugger 0.11.0
Licensed under GNU GPL v2
For bug reports, read
Info : auto-selecting first available session transport "hla_swd". To override use 'transport select <transport>'.
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
Info : clock speed 1800 kHz
Error: open failed
in procedure 'program'
** OpenOCD init failed **
shutdown command invoked

make: *** [../../libDaisy/core/Makefile:332: program] Error 1

I recently switched from windows and there everything works so it’s not a hw/connection issue how is suggested in the similar topics. Any help please?

I had the same issue. Installing openocd v0.12 solved it.

Yes, I also thought that because this is how I fixed the same issue once on Win. But trying to install it on Ubuntu I got completely lost :frowning: Can you describe the process a bit please?

I would start with the official documentation how to deploy:

Hey, just wanted to confirm that installing openocd v.0.12 indeed fixes the problem. There are prebuilt binaries including the ones for ubuntu available here xPack github

Thank you @KnightHill !

1 Like