mirror of
https://gitlab.com/asus-linux/asusctl.git
synced 2026-02-06 00:15:04 +01:00
Move DBUS and keyboard reads on to tokio
This greatly improves throughput of per-key LED effects. Also add a cool-down timer in the main loop to adjust thread speed and prevent it running at maximum speed.
This commit is contained in:
@@ -46,7 +46,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||
|
||||
// It takes each interrupt at least 1ms. 10ms to write complete block. Plus any extra
|
||||
// penalty time such as read waits
|
||||
let time = time::Duration::from_millis(1); // aim for 60 per second
|
||||
let time = time::Duration::from_millis(10); // aim for 100 per second
|
||||
|
||||
let row = KeyColourArray::get_init_msg();
|
||||
let msg =
|
||||
|
||||
Reference in New Issue
Block a user