]> www.infradead.org Git - users/dwmw2/esp32-pool.git/commitdiff
update from MQTT
authorDavid Woodhouse <dwmw@amazon.co.uk>
Wed, 7 Aug 2024 21:59:03 +0000 (22:59 +0100)
committerDavid Woodhouse <dwmw@amazon.co.uk>
Wed, 7 Aug 2024 21:59:03 +0000 (22:59 +0100)
paper.yaml

index fb0591ba7d6c55bcdb78aff18adda35ec5ed29fe..95fb7f5418981c7e73548d13406d93d27da11a7e 100644 (file)
@@ -67,17 +67,27 @@ spi:
   clk_pin: GPIO39
   mosi_pin: GPIO40
 
+text_sensor:
+  platform: mqtt_subscribe
+  name: Text
+  id: display_text
+  topic: epaper/text
+  on_value:
+    - component.update: epaper_display
+
 display:
   - platform: waveshare_epaper
+    id: epaper_display
+    data_rate: 20MHz
     cs_pin: GPIO38
     dc_pin: GPIO37
     busy_pin:
       number: GPIO35
       inverted: true
     reset_pin: GPIO36
-    model: 7.50inV2
+    model: 7.50inV2alt
     reset_duration: 2ms
-    update_interval: 30s
+    update_interval: never
 #    full_update_every: 60
     lambda: |-
-      it.print(0, 0, id(font1), "Hello World 7.50inV2 ESP-IDF inv!");
+      it.print(0, 0, id(font1), id(display_text).state.c_str());