diff options
author | Evgeny Zinoviev <me@ch1p.io> | 2024-02-24 02:03:28 +0300 |
---|---|---|
committer | Evgeny Zinoviev <me@ch1p.io> | 2024-02-24 02:03:28 +0300 |
commit | 9be0c3125dd5302c409b6a0fe37b8224b163209f (patch) | |
tree | e66100c47bc17ef10e089ca86cc77310e7e44083 /bin | |
parent | c9b351a08e31aa0c34892065f02f9ef710b6cd34 (diff) |
temphum_mqtt_node: use correct data topic
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/temphum_mqtt_node.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/temphum_mqtt_node.py b/bin/temphum_mqtt_node.py index 4259f65..3f1c911 100755 --- a/bin/temphum_mqtt_node.py +++ b/bin/temphum_mqtt_node.py @@ -9,7 +9,7 @@ from typing import Optional from argparse import ArgumentParser from homekit.config import config from homekit.mqtt import MqttNodesConfig, MqttNode, MqttWrapper -from homekit.mqtt.module.temphum import MqttTempHumModule, MqttTemphumDataPayload +from homekit.mqtt.module.temphum import MqttTempHumModule, MqttTemphumDataPayload, DATA_TOPIC from homekit.temphum import SensorType, BaseSensor from homekit.temphum.i2c import create_sensor @@ -53,7 +53,7 @@ async def on_sched_task(): rh, temp = await get_measurements() payload = MqttTemphumDataPayload(temp=temp, rh=rh) - _mqtt_node.publish('data', payload.pack()) + _mqtt_node.publish(DATA_TOPIC, payload.pack()) if __name__ == '__main__': |