aboutsummaryrefslogtreecommitdiff
path: root/examples/nrf52840/src/bin/usb_hid_keyboard.rs
diff options
context:
space:
mode:
Diffstat (limited to 'examples/nrf52840/src/bin/usb_hid_keyboard.rs')
-rw-r--r--examples/nrf52840/src/bin/usb_hid_keyboard.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/examples/nrf52840/src/bin/usb_hid_keyboard.rs b/examples/nrf52840/src/bin/usb_hid_keyboard.rs
index 5a9dc90a2..1cd730503 100644
--- a/examples/nrf52840/src/bin/usb_hid_keyboard.rs
+++ b/examples/nrf52840/src/bin/usb_hid_keyboard.rs
@@ -6,10 +6,10 @@ use core::sync::atomic::{AtomicBool, Ordering};
6use defmt::*; 6use defmt::*;
7use embassy_executor::Spawner; 7use embassy_executor::Spawner;
8use embassy_futures::join::join; 8use embassy_futures::join::join;
9use embassy_futures::select::{select, Either}; 9use embassy_futures::select::{Either, select};
10use embassy_nrf::gpio::{Input, Pull}; 10use embassy_nrf::gpio::{Input, Pull};
11use embassy_nrf::usb::vbus_detect::HardwareVbusDetect;
12use embassy_nrf::usb::Driver; 11use embassy_nrf::usb::Driver;
12use embassy_nrf::usb::vbus_detect::HardwareVbusDetect;
13use embassy_nrf::{bind_interrupts, pac, peripherals, usb}; 13use embassy_nrf::{bind_interrupts, pac, peripherals, usb};
14use embassy_sync::blocking_mutex::raw::CriticalSectionRawMutex; 14use embassy_sync::blocking_mutex::raw::CriticalSectionRawMutex;
15use embassy_sync::signal::Signal; 15use embassy_sync::signal::Signal;
@@ -210,7 +210,9 @@ impl Handler for MyDeviceHandler {
210 210
211 fn suspended(&mut self, suspended: bool) { 211 fn suspended(&mut self, suspended: bool) {
212 if suspended { 212 if suspended {
213 info!("Device suspended, the Vbus current limit is 500µA (or 2.5mA for high-power devices with remote wakeup enabled)."); 213 info!(
214 "Device suspended, the Vbus current limit is 500µA (or 2.5mA for high-power devices with remote wakeup enabled)."
215 );
214 SUSPENDED.store(true, Ordering::Release); 216 SUSPENDED.store(true, Ordering::Release);
215 } else { 217 } else {
216 SUSPENDED.store(false, Ordering::Release); 218 SUSPENDED.store(false, Ordering::Release);