Open usedbytes opened 2 weeks ago
OffTopic: https://github.com/raspberrypi/usb-pid says 2e8a:000a is "Raspberry Pi Pico SDK CDC UART (RP2040)" so I've no idea why lsusb
is listing it as "Pimoroni Badger2040" ??
That’s just a string descriptor reported by my FW. lsusb
doesn’t have a database or anything, it’s just printing what the device says in the Manufacturer and Product ID strings.
I originally wrote the code for a Badger 2040 and looks like I never changed the string.
I think I've found the cause of this segfault - could you test with that new branch and see if it fixes this for you? https://github.com/raspberrypi/picotool/tree/no-usb-segfault-fix
This is ~ a re-report of #119 , but I think the report there is unclear/misleading.
If picotool can't open the device (
ret = libusb_open(device, dev_handle);
fails), thenhandle
will end up as0x0
in the device map, and (for example)reboot_device
will segfault.My Pico (RP2040) is reporting vid:pid
2e8a:000a
(Note the HW is actually a plain Pico, not a Badger2040, but that shouldn't matter)At the very least I think the null handle should be checked/caught and something useful reported to the user ("Couldn't open device"), rather than segfaulting.