ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor

In this tutorial we will build ESP8266 WiFi Arduino temperature and humidity data logger. Data will be stored on EasyIoT server and displayed in web browser on remote computer or on mobile phone. With ESP8266 EasyIoT Arduino library you can build sensor with couple lines of code. You can add up to 65535 sensor nodes to one EasyIoT server.

EasyIoT server supports secure SSL connection - ESP8266 does not.

Step 1: Materials

ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor

ESP8266 WiFi module

Arduino pro mini 8Mhz 3.3V

DHT22 temperature and humidity sensor

5V power supply

AMS1117 3.3 regulator

Capacitor 1000uF

EasyIoT server (Windows machine or Raspberry Pi)

WiFi network (WiFi router)

Step 2: Build sensor node

ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor

Conenct Arduino pro mini, ESP8266, power supply and DHT22 temperature humidity sensor.

VCC 3.3 V to Arduino pro mini

VCC 3.3V to DHT22 sensor VCC

VCC 3.3V to ESP8266 VCC module

VCC 3.3V to CH_PHD pin on ESP8266 module

connect GND on Arduino, DHT22, ESP8266 and power supply GND

connect pin 3 on Arduino to pin RST pin on ESP8266

connect pin 10 on Arduino to pin UTXD pin on ESP8266

connect pin 11 on Arduino to pin URXD pin on ESP8266

connect pin 2 on Arduino to pin DATA pin on DHT22

After you connect wires upload program to Arduino sensor node. Before we start using ESP8266 WiFi module we need to update ESP8266 firmware. We use V0.9.2.2 version of firmware. Detail instructions how to update firmware can be found here.

ESP8266 temperature humidity program is on GitHub. Don't forget to set correct access point username and password and EasyIoT serverIP address in Esp8266EasyIoTConfig.h

Step 3: Build EasyIoT server

ESP8266 WiFi temperature and humidity sensor

EasyIoT server will be responsible for logging sensor data. You can add up to 65535 ESP8266 WiFi sensor nodes to one EasyIoT server.

If you are using Windows machine: just download latest release of EasyIoT server win release and unzip it to Windows machine. Run EasyIoT.exe under administrator privileges.

Or if you are using Raspberry Pi: download latest version of EasyIoT server disc image to SD card. Windows users can write EasyIoT server image to SD card with Win32 Disk Imager.

Put SD card in Raspberry Pi and switch on Raspberry Pi. Raspberry Pi must be on same network as ESP8266 module.

Step 4: Add Sensor node to EasyIoT server

ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
Show All 9 Items

In web browser on computer enter Raspberry Pi IP address. Use username admin and password test when asked.

Go to Configure->Drivers->ESP8266 EasyIoT driver and enable driver. Press button Add Node and switch on your ESP8266 Arduino sensor. After couple of seconds you should see two added sensor modules (no timeout message). Then go back and add new modules to Group and modules and enable data logging (see attached pictures).

Step 5: Display data

ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor
ESP8266 WiFi temperature and humidity sensor

Go in Web browser in computer and enter IP address of your Raspberry Pi. On front page you should see current temperature and humidity and chart of temperature and humidity.

Display data in web browser on remote computer or on mobile phone.

 
 

Tag cloud

make build easy simple arduino making homemade solar laser printed portable cheap mini building custom cardboard wooden create super lego turn paracord chocolate your paper light intel