From 82df106df1aa9d36541c1c4ad9e336b72bdbbba3 Mon Sep 17 00:00:00 2001 From: Nicu Hodos Date: Thu, 2 Oct 2025 16:34:51 +0200 Subject: [PATCH] use uppercase ON/OFF when reading contact sensor type - it aligns with home assistant --- include/TinyComponent.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/TinyComponent.h b/include/TinyComponent.h index 725fce1..999d5f7 100644 --- a/include/TinyComponent.h +++ b/include/TinyComponent.h @@ -24,7 +24,7 @@ bool buildSensorJson(unsigned long value, JsonDocument& jsonDoc) { sensor["humidity"] = (float)GET_HUMIDITY(value) / 10; break; case SensorType::CONTACT: - sensor["state"] = GET_STATE(value) ? "on" : "off"; + sensor["state"] = GET_STATE(value) ? "ON" : "OFF"; break; default: return false;