From 7ce2594eb78a0160928d6a39b778f552f034ddc3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?D=C3=A1niel=20Buga?= Date: Fri, 26 Apr 2024 18:18:08 +0200 Subject: [PATCH] Reset inited flag to allow re-enabling --- embassy-stm32/src/usb/otg.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/embassy-stm32/src/usb/otg.rs b/embassy-stm32/src/usb/otg.rs index 0525718e1..fa1a80b17 100644 --- a/embassy-stm32/src/usb/otg.rs +++ b/embassy-stm32/src/usb/otg.rs @@ -245,6 +245,7 @@ impl<'d, T: Instance> Bus<'d, T> { T::Interrupt::disable(); ::disable(); + self.inited = false; #[cfg(stm32l4)] crate::pac::PWR.cr2().modify(|w| w.set_usv(false));