Skip to content

ismenc/esp8266-mqtt-control

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ESP8266 remote controller via MQTT

This program allows us to control a relay attached to an ESP8266 (over NodeMCU board) through the MQTT protocol. With the mobile app, we can control it from anywhere.


Navigation


:octocat: GitHub Repository
📱 Android App
⬇️ Releases
📝 Issues


How can I collaborate?

Instructions

  1. ✌️ Fork this repository and clone through terminal git clone <url>.
  2. 📂 Set the directory on the cloned folder cd <folder>.
  3. 📝 Modify the project as you wish.
  4. ✨ Stage the changes git add * and create new commit: git commit -am "Summary of changes".
  5. ⬆️ Upload your work: git push origin master.
  6. 📧 Feel free to initiate a pull request :D

:octocat: Si deseas aprender Git, visita mi guía sobre Git.


Index




1. Functionality

MQTT is a machine-to-machine "Internet of Things" connectivity protocol and a extremely lightweight publish/subscribe messaging transport.

This application connects to a MQTT broker (wich you can find for free) and listens to the topic lights under home (/home/lights). If it receives '1' or '0' starting strings, the ESP will turn on or off a relay wich controls lights. It also publishes status info at the topic /home/log.

I also made a simple Android app for this program at this repository.

2. How to use

You will need:

✅ To install drivers for your board depending on the system.

✅ A well installed Atom text-editor with PlatformIO environment installed.

✅ A cloud MQTT broker. (ok, take this one)

You will need the knolleary's great 📚 PubSubClient library for your own projects wich is included under the lib directory. It can also be installed via PlatformIO home at Atom, Libraries.

🚀 After that you can just clone this repository through atom or Git and modify and upload the main sketch. The program uses the main functions of the library but you can always check knolleary's PubSubClient documentation for more.

Finally, in case you need in depth information about hardware or library, checkout his repo 📚 PubSubClient library.

If you have any question -> open an 📝 Issue.