lua

IoT and MQTT

Ok, my previous blog entry outlined how to make the NodeMCU board a lot more useful by adding the DHT22 sensor which captured temperature and humidity. This is nice but does require a serial connection between my Linux machine and the NodeMCU board to make the information measured visible. Requiring a hardwired serial cable to establish connectivity made this prototype a lot less useful in the world of IoT. The objective of this blog post is to 'Cut the Serial Cord' and go wireless. Here is where the ESP8266 chipset…

Keep reading

Capturing Sensor Data: DHT22

Ok, having blinking LED's connected to an ESP8266 SOC is nice but is not very useful in terms of information exchange and/or interaction. This blog builds a simple IoT application which measures temperature and humidity and returns the measured values. This build is relatively straightforward build as we can leverage DHT22 temperature-humidity sensor and the corresponding native NodeMCU dht module. Breadboard sketch We need to wire up the DHT22 sensor to the NodeMCU which will provide ground and power - black and red wires respectively. Second the sensor data…

Keep reading

Super Bowl L(ed)

With the kick-off of Super Bowl L between the Carolina Panters and the Denver Broncos a few hours away I decided to show the ultimate team spirit and blink my NodeMCU and RGB LED in the colors of Broncos Country: orange and blue. It makes for an excellent opportunity to get some hands on experience with Pulse-Width Modulation and NodeMCU's PWM module before the big game kick-off. Orange/Blue Blink! A common method to 'mix' a custom color of a RGB LED is by controlling the brightness of each of…

Keep reading

Blink!

Like all programming languages the first program you typically write is “Hello, World!” which illustrates the basic syntax of the language. In the world of IoT a similar phenomenon exists: “Blink!” Blink! is a basic set of instructions which toggles a LED light on or off. This post outlines the steps to toggle an LED using Lua on NodeMCU. This post assumes that you have a ESP8266 is flashed with the latest NodeMCU firmware. I have written an extensive post on that topic here. "Lua" (pronounced LOO-ah) means "Moon" in…

Keep reading