feat: Added Typed impl for all automation devices

To accomplish this a basic implementation was also provided for some
types in automation_lib
This commit is contained in:
2025-10-10 03:47:52 +02:00
parent 76eb63cd97
commit 1532958a86
24 changed files with 296 additions and 46 deletions

View File

@@ -1,6 +1,7 @@
use std::net::{Ipv4Addr, SocketAddr};
use std::time::Duration;
use lua_typed::Typed;
use rumqttc::{MqttOptions, Transport};
use serde::Deserialize;
@@ -52,7 +53,7 @@ fn default_fulfillment_port() -> u16 {
7878
}
#[derive(Debug, Clone, Deserialize)]
#[derive(Debug, Clone, Deserialize, Typed)]
pub struct InfoConfig {
pub name: String,
pub room: Option<String>,
@@ -68,7 +69,7 @@ impl InfoConfig {
}
}
#[derive(Debug, Clone, Deserialize)]
#[derive(Debug, Clone, Deserialize, Typed)]
pub struct MqttDeviceConfig {
pub topic: String,
}