Category

ESP8266

C# Windows IoT Core Serial Communications with an ESP8266

By | Blogs, C#, ESP8266, git, Hardware, IoT, Microsoft, Multi-Device, News, Raspberry Pi, Visual Studio, Windows Universal Apps | No Comments

Windows IoT Core is great for connecting single board computers such a Pi2 to an ESP8266, via a serial link. The hardware for such a link can be found in my previous post here. The details for a basic serial communication C# framework are detailed in this post. If you have an ESP8266, there are numerous ways of communicating with them such as LuaLoader. However, I needed to communicate with my ESP8266 through a Pi2 running Windows IoT Core. This is part of a larger automated test project for an upcoming consumer project we’re developing. In this post, I’ll cover…

Read More

How to Build the NodeMCU Firmware using BoUoW

By | ESP8266, IoT, Linux, Windows | No Comments

This is post 13 of 13 in the series “IoT with the ESP8266” The Windows 10 Anniversary Update includes the Windows Subsystem for Linux, as I had mentioned in a previous post. The Bash shell (succinctly named “Bash on Ubuntu on Windows”, or BoUoW if you’re actually trying to search for information) permits native Linux ELF64 binaries to run on Windows. It’s pretty clever, but a little limited in areas. So, I wondered: since Linux is the preferred first-class build environment for ESP8266 firmware, can I build the NodeMCU firmware using BoUoW? Let’s find out! First, you will need to activate the feature and install BoUoW….

Read More

Quick serial clip connector for your multiple IoT PCBs

By | Blogs, ESP8266, IoT, News | No Comments

You don’t need a fancy USB serial connector for your multiple IoT PCBs. It’s easy to create your own quick and inexpensive connector. This is an example of a simple quick-connect serial clip that can connect a PCB- mounted ESP8266 to a computer via USB. If you don’t want the expense or bother of soldering on a fancy USB connector to your many IoT PCBs for flashing and/or programing your ESP (or other) device, you have options. I worked out an easy, cheap, and reliable method of making a quick short-term connection. You need a few things. Some parts you…

Read More
Wi-Fi

ESP8266 and Wi-Fi Channels

By | ESP8266, IoT | 4 Comments

This is post 10 of 13 in the series “IoT with the ESP8266” The ESP8266 supports operating as a Wi-Fi station (station mode), an access point (softAP mode), and can even do both at the same time (softAP+station mode). However, there is one important detail that must be understood or else it will come back to bite you: the radio in the ESP8266 only supports one hardware channel at a time. What does this mean? Well, 802.11b/g/n operating on 2.4GHz has 14 different channels that can be used (though, in North America, we can only use channels 1-11 due to…

Read More

ESP8266/NodeMCU Deep Sleep

By | ESP8266, IoT | 8 Comments

This is post 9 of 13 in the series “IoT with the ESP8266” Sometimes, an IoT device will perform small chunks of work, and then will otherwise be idle. For instance, a weather station with sensors for temperature, pressure, and humidity (such as the BME280) may only need to take a reading every 15 minutes and broadcast to the cloud – something that requires 10 seconds to accomplish. If the device is powered by a battery, then you want it to enter a deep sleep state in between the work cycles in order to maximize battery life. But, how would you force an ESP8266 to…

Read More

Programming GPIO on the ESP8266 with NodeMCU

By | ESP8266, IoT | 10 Comments

This is post 8 of 13 in the series “IoT with the ESP8266” IoT devices (a.k.a., Things) aren’t very interesting if they cannot interact with the world around them. As Makers, we need to hook up sensors, light up LEDs, and communicate with other devices that are wired up to our Things. To do this, we need IO functionality that can be programmed. GPIO (General Purpose Input/Output) refers to a set of generic pins of a microcontroller that can be used for digital signaling. GPIO pins can be individually set to act as input or output, and values can be either…

Read More

Working with Files in NodeMCU on the ESP8266

By | ESP8266, IoT | 6 Comments

This is post 7 of 13 in the series “IoT with the ESP8266” What is SPIFFS? One of the coolest things about the NodeMCU firmware is that it includes a SPI Flash File System (SPIFFS) module. This means that data and scripts can be written to and read from the flash memory using the concept of files instead programming against raw memory locations. Flash memory allow random access reads and writes. But, by nature, flash memory only allows erasure for entire blocks of memory (i.e., 64 kB) at a time. When erased, a NOR flash memory address will contain all…

Read More

Let’s Do Something with the ESP8266 using NodeMCU

By | ESP8266, IoT | 3 Comments

This is post 6 of 13 in the series “IoT with the ESP8266” Get to a Prompt Up until now, I’ve been putting out a lot of high-level background information about the ESP8266 and different firmware in order to establish a baseline of knowledge about the platform and its history. Now that you [hopefully] have NodeMCU installed onto your own ESP8266 device, let’s do something with it. Connect your device to the USB port, and open a serial terminal program. If you’re looking for a serial terminal for Windows, then you may want to try out RealTerm. It has become my…

Read More

How to Wire the ESP8266-12 for Programming

By | ESP8266, IoT | 8 Comments

This is post 5 of 13 in the series “IoT with the ESP8266” In my last post, I discussed how to acquire the NodeMCU firmware, and then how to flash it using a serial port (or, rather, your USB port). The assumption that I was making was that people already had the ESP8266-12 module in an easy-to-work-with form, like the NodeMCU DevKit or Adafruit Huzzah. But, some of the readers only had the bare module. I was asked what it would take to ready the ESP8266-12 module itself for programming. My response follows: ESP8266-12 Pinouts Here are the pinouts of…

Read More

NodeMCU Firmware for the ESP8266

By | ESP8266, IoT | No Comments

This is post 4 of 13 in the series “IoT with the ESP8266” Introducing NodeMCU The NodeMCU Firmware is an open source project that provides an abstraction layer on top of the Expressif SDK for the ESP8266. While the SDK itself provides low-level access to the peripherals of the ESP8266EX chip, NodeMCU provides a high level API that hides a lot of the implementation details of how the chip works. NodeMCU includes a version of the Lua programming language that is based on eLua. Like many developers, I was personally first introduced to the Lua language by means of a…

Read More

ESP8266 Firmware

By | ESP8266, IoT | 3 Comments

This is post 3 of 13 in the series “IoT with the ESP8266” Firmware is the term given to software that runs from non-volatile memory (NVM) on a piece of hardware. It is the “permanent” program stored in the ROM of any device that contains a processor, like your TV’s remote control, your digital camera, your Wi-Fi router, and even modern light bulbs (the programmable LED ones). It is considered non-volatile because the program survives power-down states without requiring any sort of supplemental battery power. Historically, a device’s firmware is set during manufacturing and never changed. Though, since re-writable flash…

Read More

Introducing the ESP8266-12 Module

By | ESP8266, IoT | No Comments

This is post 2 of 13 in the series “IoT with the ESP8266” Don’t let the $2-3 price fool you: there is a lot of functionality packed into the ESP8266-12 module by Chinese manufacturer AI-Thinker. The ESP8266EX itself is a System on Chip (SoC) produced by another Chinese manufacturer, Espressif. Within this tiny 5mm TSLP package is: a 32-bit 80 MHz microcontroller based on the Tensilica LX106 64 KB of Instruction RAM, 96 KB of data RAM Built-in 2.1 GHz 801.11 b/g/n Wi-Fi interface (TR Switch, Balun, LNA, Power Amplifier, and Matching Network) 17 GPIO pins with internal pull-up/pull-down resistors…

Read More

Why is IoT so Expensive? Hint: It Doesn’t Have to Be!

By | ESP8266, IoT | One Comment

This is post 1 of 13 in the series “IoT with the ESP8266” So often today, I see the Internet of Things (IoT) as being associated with small form-factor general-purpose computers, like the Raspberry Pi 2, the Intel Galileo, and the MinnowBoard MAX. Don’t get me wrong: these are all great platforms for prototyping just about anything, offering fast multi-core processors, a reasonable amount of RAM by today’s standards, a plethora of I/O, and external removable storage (i.e., SD card) all at a reasonable cost if you are buying one or two… but at $35, $45, and $145, these are…

Read More