Added OnPresence trait that allows devices to act on changes in presence

This commit is contained in:
2022-12-29 00:24:00 +01:00
parent 8dc3fd42e7
commit 924b3cf862
9 changed files with 145 additions and 18 deletions

View File

@@ -10,6 +10,7 @@ use crate::devices::{DeviceBox, IkeaOutlet, WakeOnLAN};
pub struct Config {
pub mqtt: MQTTConfig,
pub fullfillment: FullfillmentConfig,
pub presence: MqttDeviceConfig,
#[serde(default)]
pub devices: HashMap<String, Device>
}