miflora-mqtt-daemon icon indicating copy to clipboard operation
miflora-mqtt-daemon copied to clipboard

DateTime over mqtt-json

Open ThomDietrich opened this issue 6 years ago β€’ 2 comments

https://community.openhab.org/t/xiaomi-mi-flora-plant-sensor-mqtt-client-daemon/33119/53

https://github.com/ThomDietrich/miflora-mqtt-daemon/blob/a7a474b196c7cd299b939a47737ddbac17124b5e/miflora-mqtt-daemon.py#L337

Add:

data['timestamp'] = strftime('%Y-%m-%dT%H:%M:%S', localtime())

Maybe add timezone? Also the openHAB generator function needs to be adapted.

ThomDietrich avatar Jan 16 '18 15:01 ThomDietrich

I would prefer Zulu time (UTC) πŸ˜„

hakan42 avatar Dec 17 '18 15:12 hakan42

I will soon add some updates to this project, especially because of Homie v3, see #57

ThomDietrich avatar Dec 17 '18 18:12 ThomDietrich