13

I just started looking into MQTT protocol.

Situation

In my college project, currently, I use Arduino as main MCU and do every work in that and use Serial Comm. to send AT commands to esp8266 (for HTTP requests, to run scripts on server etc). I basically needed to push some data(from Arduino) on a webpage(hosted by a local server). I searched and found about MQTT protocol which enables to publish and subscribe data on clients(Exactly what I wanted). But most of the tutorials I am finding are either entirely on Arduino(with wifi shield) or entirely on esp8266.

What I want to know is that is there a possible way to use MQTT as with my current configuration? That is, using Arduino to do all the work and by using its serial comm. Publishing data just by AT commands on MQTT.

Additional Information about my project is mentioned here : Confused about which technology to use in Smart Home System

Salim Shamim
  • 753
  • 1
  • 5
  • 15

1 Answers1

5

I finally found a tutorial by Sony Arouje. As it turns out I had to completely abandon manual sending of esp commands and had to use the library (WiFiEsp.h). Hint...It's better!

Though initially it didn't work with my esp8266 because it had an older firmware and reported error "firmware not supported". I had to flash a newer Firmware (works with version 1.54 in my case). Anyone having problem flashing firmware may find some help referring this topic: Can't Flash ESP8266 latest firmware, says "Fast Flashing error" and "Invalid head of packet(' ')"

Also, I have saved a copy of all download tools and the tutorial page itself, so if in the future, the post is removed or if anyone doesn't finds the tools to flash. Get to me in comments or something (not posting here because I don't know if it's ok to post someone else's content)

Salim Shamim
  • 753
  • 1
  • 5
  • 15