How was the data logger made?
The Solar water heater LIVE Logger is built with OPEN SOURCE hardware and code.
The main microcontroller is an ESP8266 WiFi, accompanied by sensors such as:
- DS18B20 for measuring the temperature inside the solar water heater boiler
- DHT21 for measuring ambient temperature
- LDR for measuring light intensity
The webcam image is transmitted by an ESP32-CAM connected to the internet.
The ESP8266 and ESP32-CAM are programmed using the ARDUINO IDE environment.
For data storage and presentation, PHP/MySQL, WordPress, Google Charts, etc. are used.
HARDWARE
ESP8266 Microcontroller
The ESP8266 is an inexpensive and versatile Wi-Fi module widely used for IoT (Internet of Things) applications. It has built-in Wi-Fi, can be programmed in C or Lua, and supports multiple communication protocols such as HTTP and MQTT. It features a Tensilica L106 microcontroller running at 80 or 160 MHz and can connect with various sensors and devices via its GPIO pins. It is used for remote control and data collection in automation projects, smart homes, and other networking applications. This microcontroller is used by the SolarWaterHeater.Online project for data collection, chosen for its low cost and the wide availability of libraries and resources.
Waterproof DS18B20 Temperature Sensor
The DS18B20 is a high-accuracy digital temperature sensor communicating via the 1-Wire protocol. It can measure temperatures from -55°C to 125°C with an accuracy of ±0.5°C within the range of -10°C to 85°C. One key feature is the ability to connect many sensors on the same bus, thanks to the unique 64-bit address of each sensor. It is used in various applications such as ambient temperature measurement, liquid temperature, and temperature control systems. This sensor is suitable for measurements inside tanks due to its shape. It can be placed inside the electric thermostat pipe of the boiler and can measure over 100 degrees Celsius, which is necessary for our case. It is waterproof and can measure even in liquids, though that is not required here.
DHT21 Temperature and Humidity Sensor
The DHT21 (or AM2301) is a digital temperature and humidity sensor. It can measure temperature with ±0.5°C accuracy and relative humidity with ±3% accuracy. The sensor outputs data through a digital signal, making it ideal for use with microcontrollers like the ESP8266. It is commonly used in climate control applications such as smart HVAC systems, weather stations, and other environmental monitoring. From our experience and other projects, this sensor is recommended. It is reliable both in measurements and continuous operation.
LDR Light Intensity Sensor
ESP32-CAM WiFi Module
SOFTWARE
This page refers to the SOFTWARE requirements for the SolarWaterHeater.Online project.
The programming language PHP and the database MySQL are two of the most popular technologies for developing dynamic websites and web applications. The combination of PHP and MySQL is common in applications like WordPress, Joomla, and other platforms, offering flexibility, speed, and ease of development.
In our case, the site is hosted on WordPress. For storing the data sent by the microcontroller, we used a MySQL database with PHP as the programming language that manages, processes, and displays the data on the site. Visualization is done through Google Charts.
PHP
PHP is a server-side programming language designed to create dynamic content and interact with databases. It is widely used for web and application development, allowing logic execution, content management, and dynamic web page