When the device I'm talking to sends binary data, I can recover most of it. However, it always seems that some bytes are missing, replaced by non-standard characters. For example, one separate output is as follows:
\xc4\xa5\x06\x00.\xb3\x01\x01\x02\x00\x00\x00=\xa9
The period and equals character must be a traditional byte in hexadecimal format (I confirmed this in another application). Other times, I get other strange characters, such as ')' or 's'. These characters are usually found in the same place (which depends on the command sent to me on the device).
How can I fix this problem?
source
share