Sending sensor data via sim800l through mqtt

i am working on a home automation using arduino and sim800l , at first i thought of using thinkspeak IOT server
with a web interface will work with HTTP REST API but the problem is i need to continuously request a channel feed and if there is a change in the feed then it will change the room controls accordingly. In this procedure there will be lager delay for requesting HTTP API and then processing it .
then i searched a lot came to know mqtt is the best, i have seen your videos on mqtt in youtube , in your video you send the data after converting the data into binary (i did not understand why?) now what if i want to continuously want to send room temperature to mqtt cloud , do i need to convert every time the temperature text into binary and upload it.
Is there any way that we could send ASCII text format values

MQTT is a binary protocol. It has to be in binary. Especially the commands. The data can be in ASCII, no problem. But the formation of control packet fields should be in binary.

Hey, please have look on this article which Might Help you out in using MQTT broker with thingspeak

1 Like