Note28 October 20211 min read
A local weather station, in two repositories
ESP8266 firmware reads temperature, humidity, rain, and light, and a separate MATLAB repository analyzes that station's data.
Steven Kamwaza
The station firmware is in weather-staion-iot. It is one Arduino sketch for an ESP8266. A DHT11 on pin D4 supplies temperature and humidity. A digital rain sensor is on D3. An LDR on A0 supplies a light reading. A buzzer on D1 turns on after the rain input has stayed high for five seconds.
Readings go to a ThingSpeak channel as four fields: temperature, humidity, rain, and light. The same loop writes temperature, humidity, rain, and a timestamp into Firebase Realtime Database under /weatherdata, on a three-minute timer, using NTP for the time.
The analysis lives in a second repository, weather_station_matlab_analyist_code. That README describes MATLAB code that analyzes and visualizes data from the local station. The firmware and the analysis are separate checkouts.
This is the public IoT record. The TensorFlow.js forecast demo is a separate repository.