I had a query, I’m using a network of mysensors via MQTT to display in HASS, but whenever I restart HASS I get unknown values until the values update via MQTT, which can sometimes take up to 30 mins (the nodes are battery powered).
Is there anyway to simply display the last value that HASS had for that particular sensor/device?
Using a retain flag when publishing the messages from mysensors would be the best way. But I don’t think this is supported currently. You can ask this question in the mysensors forum. Maybe they can add that feature if not done already?
You could try using some kind of middle man, to re-publish the messages at a different topic with the retain flag set.
Yes, the values are in the DB, but the current state would have to updated with the last known state. That is not currently supported, AFAIK. There is a story that should solve this: https://www.pivotaltracker.com/story/show/112736423