Hello...
I have battery powered sensor (ESP8266), and using deep sleep I wake every 15 second with WiFi off. I store data on RTC memory. Every 120 samples (30 minutes) I turn WiFi ON and send data. That's work fine with my custom protocol. Now I want to use MQTT and home assistant. How on the world I can specify the time when sample are taken?
You cannot. You may use MQTT just as a transport protocol and define your own topic to set the time or send the data as a string containing both the value and the time but probably no common listener to MQTT will use that. They will react on the MQTT event and use the time when the event arrived.
Why do you think you should change to MQTT if your custom protocol works?
As I need to add some new features (a lot of work) to my system I think it's better to switch to home assistant as there is nearly all work already done.
I can add timestamp but I think all graphs will use time of arrival instead timestamp.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.