aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--embassy-stm32/src/usb/otg.rs10
1 files changed, 4 insertions, 6 deletions
diff --git a/embassy-stm32/src/usb/otg.rs b/embassy-stm32/src/usb/otg.rs
index dc5d47006..b386c6977 100644
--- a/embassy-stm32/src/usb/otg.rs
+++ b/embassy-stm32/src/usb/otg.rs
@@ -1226,12 +1226,10 @@ impl<'d, T: Instance> embassy_usb_driver::EndpointIn for Endpoint<'d, T, In> {
1226 w.set_xfrsiz(buf.len() as _); 1226 w.set_xfrsiz(buf.len() as _);
1227 }); 1227 });
1228 1228
1229 critical_section::with(|_| { 1229 // Enable endpoint
1230 // Enable endpoint 1230 r.diepctl(index).modify(|w| {
1231 r.diepctl(index).modify(|w| { 1231 w.set_cnak(true);
1232 w.set_cnak(true); 1232 w.set_epena(true);
1233 w.set_epena(true);
1234 });
1235 }); 1233 });
1236 1234
1237 // Write data to FIFO 1235 // Write data to FIFO