Skip to content

RP2040-GEEK - supervisor USB identification cannot be set #10155

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
HidingCherry opened this issue Mar 20, 2025 · 4 comments
Open

RP2040-GEEK - supervisor USB identification cannot be set #10155

HidingCherry opened this issue Mar 20, 2025 · 4 comments
Milestone

Comments

@HidingCherry
Copy link

CircuitPython version and board name

CircuitPython 9.2.5 (also tried 9.2.4); Waveshare RP2040-GEEK

Code/REPL

# boot.py
import board
import storage
import usb_cdc

import supervisor
supervisor.set_usb_identification(
	vid=0x0123,
	pid=0x0123,
	manufacturer="manu",
	product="prod"
)

Behavior

No error.

Device should be identified as:

usb 1-4: New USB device found, idVendor=0123, idProduct=0123, bcdDevice= 1.00
usb 1-4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-4: Product: prod
usb 1-4: Manufacturer: manu

Instead it is identified as this:

usb 1-4: New USB device found, idVendor=2e8a, idProduct=1056, bcdDevice= 1.00
usb 1-4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-4: Product: RP2040-GEEK
usb 1-4: Manufacturer: Waveshare Electronics

Description

On boot the usb description should be set accordingly.

Additional information

This issue happens with the rp2040_geek images, but it does not happen with rp2040_pico (which I falsely downloaded first).

@dhalbert
Copy link
Collaborator

What OS and version are you using?

@dhalbert dhalbert added the usb label Mar 25, 2025
@dhalbert dhalbert added this to the 9.x.x milestone Mar 25, 2025
@HidingCherry
Copy link
Author

HidingCherry commented Mar 25, 2025

ArchLinux - up2date zen kernel

on boot means: on boot of rp2040-geek

@dhalbert dhalbert modified the milestones: 9.x.x, 10.x.x Mar 27, 2025
@todbot
Copy link

todbot commented Apr 14, 2025

@HidingCherry, are you doing a full reset or power cycle of the RP2040-GEEK board? The boot.py file is only run on hardware reset.
Also, most OSes cache USB descriptors, so some changes like manufacturer & product strings, will not be updated in lsusb until OS reboot I think.
Whenever I change supervisor.set_usb_identification() settings, I plug it into (another) computer that's been freshly power-cycled. This guarantees I'm not hitting any OS USB descriptor cache and that boot.py is being run.
btw, there's nothing different in the USB config for waveshare_rp2040_geek compared to raspberry_pi_pico. Any issues you're experiencing would happen with either CircuitPython build

@HidingCherry
Copy link
Author

I unplug and replug it on the same port.
I have the same code running on both builds.
Still the waveshare_rp2040_geek gives me the wrong descriptor after several tests, but raspberry_pi_pico works without issues.

I can test with different ports later this week, but I'm pretty sure the results will be the same.
I will test with current firmware ofc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants