1
0
複製 0
镜像来自 https://github.com/revspace/operame 已同步 2025-12-13 16:06:30 +00:00

Merge pull request #7 from controlco2/bugfix/publish-temp-and-hum-to-temp-and-hum-topics

bugfix: publish temperature and humidity to their own topics
This commit is contained in:
ControlCO2.space 2021-07-26 15:54:04 +02:00 committed by GitHub
當前提交 887650110f
沒有發現已知的金鑰在資料庫的簽署中
GPG key ID: 4AEE18F83AFDEB23

查看文件

@ -623,7 +623,7 @@ void loop() {
doc["value"] = t; doc["value"] = t;
doc["unit"] = "C"; doc["unit"] = "C";
serializeJson(doc, message); serializeJson(doc, message);
retain(mqtt_topic, message); retain(mqtt_topic_temperature, message);
} }
//humidity //humidity
@ -638,7 +638,7 @@ void loop() {
doc["value"] = h; doc["value"] = h;
doc["unit"] = "%R.H."; doc["unit"] = "%R.H.";
serializeJson(doc, message); serializeJson(doc, message);
retain(mqtt_topic, message); retain(mqtt_topic_humidity, message);
} }
} }
} }