Skip to content

Disable USB pullup when stopping USB - #6

Merged
UT2UH merged 1 commit into
UT2UH:VBUSfrom
matthijskooijman:disable-usb-pullups
Jan 25, 2022
Merged

UT2UH merged 1 commit into
UT2UH:VBUSfrom
matthijskooijman:disable-usb-pullups

Conversation

@UT2UH

@UT2UH UT2UH commented Jan 25, 2022

Copy link
Copy Markdown
Owner

It turns out that stopping the USB peripheral does not automatically
reset this pullup, so stopping USB (e.g. through USBDevice.detach())
would let the pullup enabled, making the USB host think the board was
still connected (but any subsequent communication would fail).
Additionally, this would use around 300μA of current.

This is a bug in the USB HAL used. This commit backports a small change
from the HAL v1.11.3 to fix this.

This fixes GrumpyOldPizza#171

It turns out that stopping the USB peripheral does not automatically
reset this pullup, so stopping USB (e.g. through USBDevice.detach())
would let the pullup enabled, making the USB host think the board was
still connected (but any subsequent communication would fail).
Additionally, this would use around 300μA of current.

This is a bug in the USB HAL used. This commit backports a small change
from the HAL v1.11.3 to fix this.

This fixes GrumpyOldPizza#171
@UT2UH
UT2UH merged commit 46ab52c into UT2UH:VBUS Jan 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants