-
-
Notifications
You must be signed in to change notification settings - Fork 8.7k
mpremote: Improve ESPxx board detection and user configuration. #17800
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
Conversation
|
Code size report: |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #17800 +/- ##
=======================================
Coverage 98.38% 98.38%
=======================================
Files 171 171
Lines 22283 22283
=======================================
Hits 21924 21924
Misses 359 359 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
329ccbb to
f4f540a
Compare
f4f540a to
48c07d6
Compare
|
Added the ESP32-C6 that uses a CH343 which was not detected.:
|
48c07d6 to
923363a
Compare
Signed-off-by: Jos Verlinde <Jos_Verlinde@hotmail.com>
Signed-off-by: Jos Verlinde <Jos_Verlinde@hotmail.com>
923363a to
8aa4844
Compare
|
Did you find this no longer necessary, after #18001 was merged? |
|
Well, there was some debate regarding maintenance, and @projectgus seemed to have a good solution, that is significantly simpler to maintain. So I wanted to reduce the PR queue. |
Summary
With modern ESPxxx boards switching to native USB , and less reliance on 3rd party UART drivers I think it is a good time to implement a better detection if a device is likely to have an MCU of the ESP32 or ESP8266 femilies
This PR adds:
when connecting to a decices port on Windows - mpremote can check if it needs ESP-Handling - and then act accordingly
if / when needed new vids/pids can be added to the default list via PRs, and included in the next release
personal / interim changes can be done by editing the mpremote config file.
In this draft the detection is based on a list of 4-tuples,
Current implementation only used the VID and PID to identify ,
the vendor could be used if if there is a need to extend matches.
The list of VIDs and PIDs has been gathered through
user configuration:
the user configuration allows to add additional PID/VIDs.
currently overriding the built-in list is not implemented
Testing
Manual testing can be done by attaching devices and running the following script:
Positive identification of:
not detected as ESPxx device.
Trade-offs and Alternatives
VID/PID versus Vendor name
Up to now the determination was done just based on the Vendor name.
See #9659
Cherry-picking
This PR contains a few cherry-picked commits from other PRs that are required to allow this PR to work.
They should be automatically dropped when this PR is rebased before merging.
Signed-off-by: Jos Verlinde Jos_Verlinde@hotmail.com