mirror of
https://github.com/embassy-rs/embassy.git
synced 2024-11-21 22:32:29 +00:00
usb: log on reset, resume, suspend
This commit is contained in:
parent
522a87ae42
commit
8fe3b44d82
@ -112,6 +112,7 @@ impl<'d, D: Driver<'d>> UsbDevice<'d, D> {
|
||||
match select(bus_fut, control_fut).await {
|
||||
Either::Left(evt) => match evt {
|
||||
Event::Reset => {
|
||||
trace!("usb: reset");
|
||||
self.bus.reset();
|
||||
|
||||
self.device_state = UsbDeviceState::Default;
|
||||
@ -122,8 +123,11 @@ impl<'d, D: Driver<'d>> UsbDevice<'d, D> {
|
||||
h.reset();
|
||||
}
|
||||
}
|
||||
Event::Resume => {}
|
||||
Event::Resume => {
|
||||
trace!("usb: resume");
|
||||
}
|
||||
Event::Suspend => {
|
||||
trace!("usb: suspend");
|
||||
self.bus.suspend();
|
||||
self.device_state = UsbDeviceState::Suspend;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user