Implement sensor status debouncing

This introduces a configurable debouncing delay before which no update
is sent to matrix, which avoids flooding the matrix room with updates
when the door is opened and closed in quick succession. It also allows
to quickly open and close the door without sending notifications.

The debouncing window can be configured in config.yml, see example.
This commit is contained in:
mirsal committed 2026-10-07 10:52:14 +00:00
1 parent bf6ccc6df1
commit 0ed1871042
3 files changed
+53 -15

No files matched your search

+1
View File
@@ -46,6 +46,7 @@ pub enum AuthConfig {
pub struct Config {
pub mqtt: MQTTConfig,
pub rooms: Vec<String>,
pub debounce_delay: u64,
#[serde(flatten)]
pub auth: AuthConfig,
pub homeserver_uri: String