-
Notifications
You must be signed in to change notification settings - Fork 143
Improve forced commands for RP2040 and custom vid/pid #263
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
base: develop
Are you sure you want to change the base?
Conversation
61e3fdd
to
ed78403
Compare
I think the "Use RP2040 workarounds on Windows when using custom vid/pid (ignored on other platforms)" stuff is assuming that if you're running a UF2 on an RP2350 with a custom VID/PID, then you'll have also modified the RP2350's OTP to report the same VID/PID in BOOTSEL mode? But I guess that might not always be the case? 🤔 |
Nope, the workaround is just to not disable the MSD, nothing to do with the actual vid/pid - if you have RP2040 stdio_usb vid/pid it autodetects that and does it automatically, but if you're using custom vid/pid then you need to tell it you have an RP2040 as it can't detect it from the vid/pid |
Okay, and how is the situation different on RP2350? |
RP2350 bootrom has the correct MS_OS_20 USB descriptors so works on Windows out of the box - whereas RP2040 doesn’t so requires drivers installed by Zadig, which only work properly when the RP2040 in bootsel mode has the MSD enabled |
Ahhhh! I knew it'd probably be something obvious that I'd forgotten 😂 Thanks for the explanation. |
The vid/pid will typically change when switching to BOOTSEL mode, so remove those filters and just filter on serial number if present Fixes #261
Calling GET_INFO when not available sometimes causes issues with forced commands Also improve libusb error messages when debugging
…with no vid/pid filtering
Also encourage -f/F on Windows, rather than a separate reboot
23843f4
to
06f43e7
Compare
Co-authored-by: Andrew Scheller <[email protected]>
This is cleaner than directing to a document name that must then be searched for the word Zadig
Co-authored-by: Andrew Scheller <[email protected]>
Allow forced commands with RP2040 on Windows - they will not deactivate the mass storage device, to ensure Zadig still works
Also fix forced commands with custom vid/pid (as they will change in bootsel mode), by removing vid/pid filters after reboot and just filtering on serial number
Fixes #260 and #261