viernes, 23 de diciembre de 2016

Expanding ports on this little ESP8266



The Hussah Breakout board based on ESP8266 chip is a little powerful development board, although for some projects the number of pins could be not enough!

Adafruit HUZZAH ESP8266 Breakout
The following are a description of the board from IO perspective.

Source: https://www.adafruit.com/product/2471
  • Reset button,
  • User button that can also put the chip into bootloading mode,
  • Red LED you can blink,
  • Level shifting on the UART and reset pin,
  • 3.3V out, 500mA regulator (you'll want to assume the ESP8266 can draw up to 250mA so budget accordingly)
  • Two diode-protected power inputs (one for a USB cable, another for a battery)
Two parallel, breadboard-friendly breakouts on either side give you access to:
  • 1 x Analog input (1.8V max)
  • 9 x GPIO (3.3V logic), which can also be used for I2C or SPI
  • 2 x UART pins
  • 2 x 3-6V power inputs, reset, enable, LDO-disable, 3.3V output
MCP23017 - i2c 16 input/output port expanderSo, if we needed to handle more than 9 outputs could be useful to have a port expander. I have used the MCP23017 (https://www.adafruit.com/product/732) and it is pretty handy and easy to use.

This port expander give us (16) I/O pins using I2C protocol, that only need (2) ESP8266 ports and give us (16) extra ports. This port expander can be used with other I2C devices and uses I2C 7-bit address between 0x20-0x27, selectable with jumpers.
 
The Huzzah Breakout board and the Feather Huzzah, based on the ESP8266 chip, have both SDA (pin 4) and SCL (pin5) for connecting the MCP23017 through I2C protocol, which are the standard pins that Arduino Wire library use. 


jueves, 22 de diciembre de 2016

ESP8266 and the new wifi things revolution

Recently I bought a Huzzah Breakout board based on ESP8266 from Adafruit. Really nice piece of technology similar to an arduino or a Teensy development board... but with Wifi capabilities!. Isn´ t that gourgeous?

https://learn.adafruit.com/adafruit-huzzah-esp8266-breakout/overview

This tiny wifi enabled micro has some amazing features:
  • 1 x Analog input (1.8V max)
  • 9 x GPIO (3.3V logic), which can also be used for I2C or SPI
  • 2 x UART pins
  • 2 x 3-6V power inputs, reset, enable, LDO-disable, 3.3V output
You can program the little beast using a preloaded Lua Interpreter, or with Arduino IDE, or even with microPython... but this last does not leave much memory to be creative... so I decided to program it using arduino programming lenguage, which is pretty good and stable, using tons of arduino libs for doing whatever the imagination is able to give us.

So, I decided to create a very interesting combination:

Hardware

  • 1x Huzzah Breakout Board
  • 1x MCP23017 16-bit port expander using I2C interface
  • 2x SainSmart 8-channel relay board
  • Raspberry Pi 2 or 3
Software
  • Socket Server using python (running on a raspberry pi)
  • Web Application using flask and python (running on a raspberry pi)

The Idea is to create a 16-way channel relay box wifi enabled to be manipulated trough a web app, that can be used from any device.

Stay Tuned...



miércoles, 4 de mayo de 2016

It´s all about connectivity

The Internet Of Things (IoT) is referred usually as a network of physical objects, that could range among sensors, vehicles, specific systems like watering systems for gardens, home security systems, whether stations... you name it.

Today everything can be connected online to internet and express themselves trough data that can be stored, analyzed and interpreted and could lead to different actions depending on the observation. These actions may be related to actuators that execute things, or may be processing and communicating data to other systems to the better understanding of it, to feed more intelligent systems, and the like.

Could be an ecosystem of technology, modular smart devices that can be related to each other in a vast super cluster of individual data producers that can be consumed via data consumers to aim to a bigger goal. Examples of this could be smart grids, smart cities, intelligent transportation, smart homes, etc.

The world is changing, and this is considered the industrial revolution of these days. We are about to ride this wave, that is becoming a huge one.

Some of the technologies that enables this phenomenon are RFID, low energy Wifi enabled Devices, Optical tags, zigbee devices, LTE enabled devices, among others.

In the following entries I will try to share some of the things that I have been doing learning how to interact and program devices to produce and recover data to build intelligent devices.