Implement dc-load inactivity display

This commit is contained in:
2026-05-28 22:49:32 +02:00
parent 058c186d63
commit 816cc35861
2 changed files with 35 additions and 14 deletions
+11 -1
View File
@@ -18,7 +18,7 @@ esphome:
comment: ${device_description}
min_version: 2024.6.0
includes:
- lab-ble-proxy-owon.h
- lab-ble-proxy.h
on_boot:
priority: 850
then:
@@ -105,10 +105,16 @@ ble_client:
then:
- lambda: |-
owon_meter.on_connect();
id(display_page) = 0;
id(lcd).update();
on_disconnect:
then:
- lambda: |-
owon_meter.on_disconnect();
if (id(display_page) == 0 && id(atorch_connected)) {
id(display_page) = 1;
}
id(lcd).update();
- mac_address: ${dl24_mac_address}
id: atorch_ble_client
@@ -116,11 +122,15 @@ ble_client:
then:
- lambda: |-
id(atorch_connected) = true;
id(display_page) = 1;
id(lcd).update();
on_disconnect:
then:
- lambda: |-
id(atorch_connected) = false;
if (id(display_page) == 1 && owon_meter.connected) {
id(display_page) = 0;
}
id(lcd).update();
atorch_dl24: