From 4c30bbd464ba96eb9e756213b1b2d2799c70f861 Mon Sep 17 00:00:00 2001 From: Kevin Date: Sun, 3 Oct 2021 18:59:50 +0200 Subject: [PATCH] Define sensors and relays from yaml file With yaml we can add class constructors matching our brew classes. See top of server for custom yaml loader constructors. --- brew.yaml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 brew.yaml diff --git a/brew.yaml b/brew.yaml new file mode 100644 index 0000000..9a8daa5 --- /dev/null +++ b/brew.yaml @@ -0,0 +1,23 @@ +--- +relays: +- !Relay + controls: cooling + pin: 14 +- !Relay + controls: heating + pin: 23 +- !Relay + controls: light + pin: 24 + +sensors: +- !bcm600 + location: inside + interval: 2 + +- !dht11 + pin: 13 + location: outside + interval: 30 + +