feat: add wait-for-idle

Signed-off-by: sisungo <[email protected]>
This commit is contained in:
2026-09-06 10:52:23 +00:00
parent 5ccbb44fb5
commit 835f213e49
6 changed files with 47 additions and 0 deletions
+4
View File
@@ -60,4 +60,8 @@ impl Client {
pub fn list_devices(&mut self, when: When) -> Result<Vec<String>, Error> {
self.invoke(&Request::ListDevices(when))
}
pub fn wait_for_idle(&mut self) -> Result<(), Error> {
self.invoke(&Request::WaitForIdle)
}
}
+3
View File
@@ -12,6 +12,9 @@ pub enum Request {
#[serde(rename = "/org.semilabs.os/LxDeviced/ListDevices@LXDEVICED_0.1.0")]
ListDevices(When),
#[serde(rename = "/org.semilabs.os/LxDeviced/WaitForIdle@LXDEVICED_0.1.0")]
WaitForIdle,
}
pub fn ser_reply<T: Serialize>(result: Result<T, Error>) -> String {