From 91a70644b2f532b3cb2bea12729d7536e67deedc Mon Sep 17 00:00:00 2001 From: yar2001Ti Date: Wed, 20 Nov 2024 11:14:33 +0200 Subject: [PATCH] Update README.md --- README.md | 45 ++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 44 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index c850877..00dfb67 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,45 @@ # EspTemperatureMonitor -This project uses esp8266 and python to measure temperatures and write to mysql database. +This project uses esp8266 and python to measure temperatures and write to MySQL database. + +# Installation + +# Requirements +Python >= 3.12 +Pip +MySql database +Esp8266 + +## pip +Install packages using pip `pip install -r requirements.txt` + +## Mysql +You need to create a database named **esp_data**. Then you can use this script to create a table: + +``CREATE TABLE 'temp_data' ( + 'id' int NOT NULL AUTO_INCREMENT, + 'temp' float NOT NULL, + 'time' timestamp NOT NULL, + 'sensor_id' int NOT NULL, + PRIMARY KEY ('id') +) ENGINE=InnoDB AUTO_INCREMENT=0 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;`` + +or you can run ``setup.py`` file. + + +### Esp8266 +To use this project you need an esp8266 with wifi support. You need only +1. port D7, 3v, GND. +2. a temperature sensor like 0750C3 +3. installed esp8266 plugin (fast [tutorial]( https://www.youtube.com/watch?v=OC9wYhv6juM&ab_channel=RuiSantos "tutorial")) +4. know your wifi ssid and password + +#### Connecting esp8266 board +Here is a photo of the schema that is used: + + +![](https://github.com/yar2000T/EspTemperature/blob/main/schema.png?raw=true) + +> [!TIP] +> You can use any esp8266 board and connect up to 8 sensors to pin D7. + +### End