Merge pull request #4360 from euphi/patch-1

Usermod BME280: Fix "Unit of Measurement" for temperature
This commit is contained in:
netmindz
2024-12-10 08:07:24 +00:00
committed by Frank
parent 3259b3acb0
commit 0095d9caac

View File

@@ -463,6 +463,7 @@ public:
configComplete &= getJsonValue(top[F("UseCelsius")], UseCelsius, true); configComplete &= getJsonValue(top[F("UseCelsius")], UseCelsius, true);
configComplete &= getJsonValue(top[F("HomeAssistantDiscovery")], HomeAssistantDiscovery, false); configComplete &= getJsonValue(top[F("HomeAssistantDiscovery")], HomeAssistantDiscovery, false);
for (byte i=0; i<2; i++) configComplete &= getJsonValue(top[F("pin")][i], newPin[i], ioPin[i]); for (byte i=0; i<2; i++) configComplete &= getJsonValue(top[F("pin")][i], newPin[i], ioPin[i]);
tempScale = UseCelsius ? "°C" : "°F";
DEBUG_PRINT(FPSTR(_name)); DEBUG_PRINT(FPSTR(_name));
if (!initDone) { if (!initDone) {