/weatherdisplay

ESP8266 based weather display with e-ink screen

Primary LanguageCMIT LicenseMIT

ESP8266 Weather display

This is a simple weather display built with ESP8266 WiFi chip and 7.4" E ink display from Pervasive Displays. Weather data is gathered from OpenWeatherMap service. Additionally, the device’s internal temperature sensor reading is sent to data.sparkfun.com service.

Most of the time the device stays in deep sleep mode consuming only 18 µA. While updating the weather power consumption varies from 80 to 150 mA. Update operation takes a few seconds, depending on WiFi router, DHCP server and internet connection speed. With 30 minute update interval 3000 mAh battery should last for a few months on one charge.

Building the software

On Linux

$ git clone https://github.com/andrei7c4/weatherdisplay
$ cd weatherdisplay/app
  • Set SDK paths and esptool parameters for your ESP8266 module in makefile
  • Finally build everything and flash the binary
$ make all
$ make flash

On Windows

  • Install Unofficial Development Kit for Espressif ESP8266
  • Download ZIP or clone this repository
  • In Eclipse select File->New->Makefile Project with Existing Code
  • Set Existing Code Location to <full path to>weatherdisplay\app and click Finish
  • In newly created project properties (C/C++ Build) change build command to mingw32-make.exe -f ${ProjDirPath}/Makefile
  • In C/C++ Build/Environment add PATH variable with paths to MinGW and MSYS, e.g. C:\MinGW\bin;C:\MinGW\msys\1.0\bin
  • In Make Target view right click on newly created project and select New
  • Set Target name to all and click OK. Repeat this for clean and flash targets.
  • Set SDK paths and esptool parameters for your ESP8266 module in makefile
  • You should now be able to build and clean the project and flash the binaries

Custom fonts and icons can be created with this tool.

Building the hardware

Any ESP8266 based module with at least 1 MB flash and SPI pins, such as ESP-12E, can be used. Development boards, such as NodeMCU-DEVKIT or similar, can be used too, but power consumption of these boards might not be as low.

The display with control board can be purchased from DigiKey. Display is connected to ESP8266 in the following way:

TCM-P74-230 ESP8266
/EN GPIO5
/BUSY GPIO4
MISO HMISO (GPIO12)
MOSI HMOSI (GPIO13)
/CS HCS (GPIO15)
SCK HSCLK (GPIO14)

Additionally, there are 3V LDO regulator, programming circuit and USB to UART bridge (CP2102 or similar can be used). Please see the schematics here.

Usage

Device settings can be changed through the serial interface (115200/8-N-1). The following syntax should be used:

parameter:value<CR>

At least the following parameters must be set by the user:

Additionally, data.sparkfun.com service keys can be set:

  • publickey
  • privatekey

If these keys are not set, internal temperature will only be shown on the display but not sent anywhere. Please see the config.c file for additional supported parameters.