Android Question cloudmqtt string format

mreyes47

New Member
Hello,
I'm pushing a mqtt message to cloumqtt which is a mqtt broker with the following.
Code: Copy
mqtt.Publish2("drawers/location", serializator.ConvertObjectToBytes("long string of about 100 characters"), 0, False)

Cloudmqtt receives the data but not in a text format. It currently shows:

Capture.JPG



Is there a way to send text via mqtt that shows up as text at cloudmqtt?
 
Solution
You are not sending text. You are sending serialized text. cloudmqtt has no way to deserialize it.

If you want to send text:
Code: Copy
mqtt.Publish2("drawers/location", "long string of about 100 characters".GetBytes("utf8"), 0, False)
Back
Top