GDB with no symbol table and OpenOCD fails libusb_open()
I’m using a Nucleo F446RE board and I’m using System Workbench 1.9.0 to debug in it.
I have CN4 jumpers ON (to enable on board MCU debug), PWR jumper on 2-3 (powered by SWD VBUS) and I connect to it using ST-Link Utility. I already upgraded ST-Link firmware and computer drivers.
I have a C++ project (mixed with C) that uses two static libraries and everything is built and linked with success. When I try to debug it (right click on the project -> Debug as -> Ac6 STM C/C++) I get this from GDB:
“No symbol table is loaded. Use the “file” command.
Function “main” not defined.”
I have -O0 and -g3 flags for every C/C++ compiler flags and -g for assembler as well.
Another problem is that OpenOCD can’t open USB device:
“adapter speed: 2000 kHz
adapter_nsrst_delay: 100
srst_only separate srst_nogate srst_open_drain connect_assert_srst
Info : Unable to match requested speed 2000 kHz, using 1800 kHz
Info : Unable to match requested speed 2000 kHz, using 1800 kHz
Info : clock speed 1800 kHz
Error: libusb_open() failed with LIBUSB_ERROR_NOT_SUPPORTED
Info : STLINK v2 JTAG v27 API v2 SWIM v15 VID 0x0483 PID 0x374B
Info : using stlink api v2
Info : Target voltage: 3.269266”
First of all, this is supposed to be using SWD and ST-Link v2-1, and it looks like it’s using V2 with JTAG (??). I’ve followed the .cfg files used for this project(nucleo_f446re.cfg)and everything looks fine.
Are these problems related?