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:
Luke
2020-04-26 22:28:25 +12:00
parent 13e736dbed
commit 8200dc85e6
8 changed files with 182 additions and 157 deletions

12
Cargo.lock generated
View File

@@ -24,17 +24,6 @@ dependencies = [
"winapi 0.3.8",
]
[[package]]
name = "async-trait"
version = "0.1.30"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "da71fef07bc806586090247e971229289f64c210a278ee5ae419314eb386b31d"
dependencies = [
"proc-macro2",
"quote",
"syn",
]
[[package]]
name = "atty"
version = "0.2.14"
@@ -631,7 +620,6 @@ name = "rog-daemon"
version = "0.6.1"
dependencies = [
"aho-corasick",
"async-trait",
"dbus",
"dbus-tokio",
"env_logger",