MQTT Binary Payload
Posted: Tue Nov 30, 2021 4:06 pm
Hi,
When transmitting via TCP I've had no problems with a binary payload, however when transmitting via MQTT, I get errors when loading after ">".
Using the command:
Any ideas why this might be? Is there a chance I'm hitting a serial control character?
I've tested with random binary data and had sporadic successes and failures, with no clear cause.
When transmitting via TCP I've had no problems with a binary payload, however when transmitting via MQTT, I get errors when loading after ">".
Using the command:
Code: Select all
sprintf(m_buffer, "AT+CMQTTPAYLOAD=0,%u\r", length);
if(sendCommand(m_buffer, 23, 500, ">")){
sendCommand(buffer, length, 1000, "\r\nOK\r\n");
}
I've tested with random binary data and had sporadic successes and failures, with no clear cause.