mirror of
https://gitlab.com/asus-linux/asusctl.git
synced 2026-02-06 00:15:04 +01:00
Am I writing slow code? No, it's the keyboard EC who is slow - Seymour
This commit is contained in:
13
src/core.rs
13
src/core.rs
@@ -128,9 +128,16 @@ impl RogCore {
|
||||
}
|
||||
|
||||
pub fn aura_write(&mut self, message: &[u8]) -> Result<(), AuraError> {
|
||||
self.handle
|
||||
.write_interrupt(self.led_endpoint, message, Duration::from_micros(1))
|
||||
.unwrap();
|
||||
match self
|
||||
.handle
|
||||
.write_interrupt(self.led_endpoint, message, Duration::from_millis(1))
|
||||
{
|
||||
Ok(_) => {}
|
||||
Err(err) => match err {
|
||||
rusb::Error::Timeout => {}
|
||||
_ => error!("Failed to read keyboard interrupt: {:?}", err),
|
||||
},
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user