The ESP8266 module has become very popular in a very short time. A new gadget for the "Internet of Things" It all started with the factory default "AT" type interface and short thereafter a NodeMCU initiative was launched where one could program the little device with the well known LUA scripting language.
As of april 2015, a new way of programming the module became available with the community driven launch of the Arduino IDE for ESP. A new era of possibilities, because many arduino libraries can be used or will be made compatible with the ESP!
It all starts with getting one! But a quick scan on eBay will show a lot of options for a very low price!
Currently there are 3 options to choose from:
- the standard firmware with "AT" style interface
- the NodeMCU firmware with the LUA script interpreter
- your very own firmware, programmed using the well known Arduino IDE
This is the stock firmware when you buy a generic ESP module. Most likely communicating on 9600 baud. Simply connect a FTDI interface and you can get started. You can use this firmware if you connect a classic Arduino boardj using the serial interface between both boards.
This firmware can be downloaded or if you buy the NodeMCU development board, it will be preloaded with NodeMCU firmware. Use a special tool to upload LUA scripts found on the internet or just write your own.
Firmware can be downloaded here: https://github.com/nodemcu/nodemcu-firmware
Handy tool for uploading LUA scripts: https://github.com/nodemcu/nodemcu-flasher
Arduino IDE for ESP
If you're familiar with programming in Arduino language (C/C++ language) then you will explore a world of new possibilities.
This is where it all starts:
Download generic Arduino IDE and configure the boardmanager for ESP
We will focus on the development of Arduino code for the ESP. Custom sketches and "multifunctional" projects are planned. Maybe we will also explore some NodeMCU LUA scripts.
At present, we have two projects in progress:
- ESP Easy - Should be the easiest way to connect your ESP to a Home Automation controller of choice...
- ESP Connexio - A basic port of the popular dutch Home Automation controller called "Nodo"
The ESP Easy has already been launched to the public on sourceforge. The ESP Connexio is still in development. The Connexio shares the webgui with the ESP project but internally it's a whole different ball game... We have to see if there's a market for this approach so maybe it will never see the 'daylight'...
Home Automation controllers
The ESP can be used in various Home Automation projects. The module can communicate through TCP or UDP and that will open up new ways to connect to your favorite Home Automation solution.
The ESP module can communicate directly with Domoticz using the HTTP interface. We will focus on Domoticz during prototyping. If you're using the ESP Easy firmware, just follow this tutorial to get you going: Tutorial_Domoticz_Switch
The Nodo is a well known Dutch Home Automation project. Currently they're working on a new release (3.8.) In the mean time, a simple but limited telnet interface between ESP and a Nodo Mega can be used.
A well known webservice to log you sensor data. Just create an account, configure firmware an you're set.