Getting the Json Out from the MQTT image in Home Assistant #1812
Replies: 1 comment
-
got it!!! using zlib.decompress(data).. |
Beta Was this translation helpful? Give feedback.
-
got it!!! using zlib.decompress(data).. |
Beta Was this translation helpful? Give feedback.
-
First of all, I know there is a card that already do it and it is installed in my instance.. it works fine. It is just a question to understand the how to.. I did program in Python (the same script that use the card). but I do not get a clear readable data out from the embedded json in the image. I get something like.. Keyword "ValedudoMap", Data: b'x\x9c\x8d[]\xab]9r\xfd/\xe7\xf94l}K~\x0bI\x1e\x06f\xa0!\x90\x97`\x9a\x13\xfbv\xcf\x05\xb7...
that is a bites array not text format.. probably compressed.. but completely undocumented as per most of what we can found on the guides... I can get the map data from the robot json via CURL but.. it would be nice to know how to decode the data embedded in the PNG.
Beta Was this translation helpful? Give feedback.
All reactions