Skip to content
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

UsbSerialJtag async breaks probe-rs on C6 on latest git #1954

Closed
dragonnn opened this issue Aug 15, 2024 · 4 comments · Fixed by #1961
Closed

UsbSerialJtag async breaks probe-rs on C6 on latest git #1954

dragonnn opened this issue Aug 15, 2024 · 4 comments · Fixed by #1961
Assignees
Labels
bug Something isn't working tests Unit, Integration, or Hardware-in-Loop Testing
Milestone

Comments

@dragonnn
Copy link
Contributor

dragonnn commented Aug 15, 2024

Hi! I update my project to latest git (to get embassy-executor match up) and my project now breaks debugging and flashing via probe-rs if I have enabled UsbSerialJtag.
This is what I get in probe-rs on first try (it flashes but after the program is running this happens:

 WARN probe_rs::session: Could not clear all hardware breakpoints: Probe(Usb(Custom { kind: Other, error: Stall }))
 WARN probe_rs::session: Failed to deconfigure device during shutdown: Probe(Usb(Custom { kind: Other, error: Stall }))
Error: An error with the usage of the probe occurred

Caused by:
    0: USB Communication Error
    1: endpoint STALL condition

This makes also the UsbSerial to stop outputting anything.
If I retry running probe-rs this is the output I get:

Error: Failed to open the debug probe.

Caused by:
    0: The debug probe could not be created.
    1: A USB error occurred.
    2: endpoint STALL condition

This worked fine before I updated esp-hal. And my project still works fine if I disable UsbSerialJtag.
To add that UsbSerial does work fine if I connect an already flashed project and do not run probe-rs, I get some hello world output.
Any idea what could cause that?

@MabezDev
Copy link
Member

We've occasionally seen the USB stall in our HIL workflow, it's possible this isn't related to USJ at all, and could be a bug somewhere else in the stack. What probe-rs version are you running by the way?

cc: @bugadani any ideas?

@bugadani
Copy link
Contributor

Sorry, do I understand you correctly? Did this work correctly for you before you updated esp-hal?

@dragonnn
Copy link
Contributor Author

@MabezDev Currently I am on 0.24.0, I updated to latest git after hitting this problem but that didn't help.
@bugadani yes, it worked fine before I updated esp-hal. Now it works fine only if you don't initialize UsbSerialJtag in my program.

@bugadani bugadani self-assigned this Aug 16, 2024
@MabezDev MabezDev added this to the 0.20.0 milestone Aug 16, 2024
@MabezDev MabezDev added bug Something isn't working tests Unit, Integration, or Hardware-in-Loop Testing labels Aug 16, 2024
@dragonnn
Copy link
Contributor Author

Thanks! That was quick, just tested it and works fine now ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working tests Unit, Integration, or Hardware-in-Loop Testing
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants