Humidity sensor update
Posted: Monday 09 January 2023 16:48
Hi,
I want to update a humidity device with python
Every sensor of the script is working execpt the Humidity sensor
This is the part of the script
Ik krijg de info, maar er gebeurd niets
I've added now the temparature because i know it uses also the temp/humidity to give a message about he climate
I've using device type=81, but also device type=82 (temp+hum) is not working
The information is read, but no info in the device
I want to update a humidity device with python
Every sensor of the script is working execpt the Humidity sensor
This is the part of the script
Code: Select all
Domoticz.Device(Name="Luchtvochtigheid", Unit=RoomHumidity, Type=81, Subtype=1, Used=1).Create()Code: Select all
def onMessagetoonTSCinfo(self, Connection, Response):
Domoticz.Debug("onMessagetoonTSCinfo called")
if 'humidity' in Response:
humidity=float(Response['humidity'])
strhumidity="%.1f" % humidity
temperature=float(Response['temperature'])
strtemperature="%.1f" % temperature
UpdateDevice(Unit=RoomHumidity, nValue=0, sValue=strtemperature+";"+strhumidity)
Code: Select all
2023-01-09 16:39:08.910 Toon: Device: 14 - ID: 637, Name: 'Toon - Luchtvochtigheid', nValue: 0, sValue: '18.8;58.0'
2023-01-09 16:40:08.187 Toon: Update 0:'18.8;58.1' (Toon - Luchtvochtigheid)
2023-01-09 16:47:37.221 Toon: Update 0:'18.7;58.2' (Toon - Luchtvochtigheid)
2023-01-09 16:47:57.224 Toon: Update 0:'18.7;58.3' (Toon - Luchtvochtigheid)
2023-01-09 16:48:17.203 Toon: Update 0:'18.7;58.2' (Toon - Luchtvochtigheid)I've using device type=81, but also device type=82 (temp+hum) is not working
The information is read, but no info in the device