Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/vitorccs/nodemcu-dht
A NodeMCU project which displays temperature and humidity data on a web page
https://github.com/vitorccs/nodemcu-dht
cplusplus dht11 dht22 nodemcu platformio
Last synced: 16 days ago
JSON representation
A NodeMCU project which displays temperature and humidity data on a web page
- Host: GitHub
- URL: https://github.com/vitorccs/nodemcu-dht
- Owner: vitorccs
- Created: 2024-01-22T01:33:16.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2024-07-20T02:47:01.000Z (7 months ago)
- Last Synced: 2024-11-18T22:36:14.185Z (3 months ago)
- Topics: cplusplus, dht11, dht22, nodemcu, platformio
- Language: C++
- Homepage:
- Size: 35.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# NodeMCU DHT Monitor
A NodeMCU project which collects temperature and humidity from DHT sensors and send them to Blynk IOT service.### Web server (http://192.168.0.1 - your LAN address)
### Web server (http://192.168.0.1/api - your LAN address)
### Blynk Dashboard
## Description
This projects requires WiFi connection with an internet link.
Additionaly, the board also acts a Web server and displays temperature and humidity in both HTML and JSON format (/api).
Note: The time is retrieved from a NTP service.## Components
* 01 - NodeMCU v2 board
* 01 - DHT-11/DHT-22 sensor
* 01 - 10K Ω Resistor - acts as a pull-up resistor
* 01 - Adafruit 128x64 OLED display (SSD1306)## About PlatformIO IDE
Platform IO is a plugin for Microsoft Visual Studio Code. It is a more robust IDE compared to the official Arduino IDE. It also allows us to easily create our own private libraries and use a more object oriented code.## Instructions
In the folder `lib\Globals`, make a copy of file `Globals.sample` to `Globals.h` and change the parameters below. Then compile and upload the project to your NodeMCU board.```c++
// WIFI
#define WIFI_SSID "MY_SSID"
#define WIFI_PWD "MY_PASSWORD"// DHT-XX
#define DHTPIN D5
#define DHTTYPE DHT22// BLYNK
#define BLYNK_TEMPLATE_ID "XXXXXXXXXXXX"
#define BLYNK_TEMPLATE_NAME "XXXXXXXXXXXX"
#define BLYNK_AUTH_TOKEN "XXXXXXXXXXXX"
#define BLYNK_UPDATE 5000// OLED
#define SCREEN_WIDTH 128
#define SCREEN_HEIGHT 64
#define SCREEN_ADDRESS 0x3C// DELAYS
#define DELAY_INIT 5000
#define DELAY_REFRESH 1000// NTP
#define NTP_TIME_ZONE 1 // Central European Time
#define NTP_SERVER_NAME "us.pool.ntp.org"
```## Fritzing file
The electronic schematic was created in the [Fritzing](https://fritzing.org/) software and can be downloaded at
[NodeMcuDht.zip](https://github.com/vitorccs/nodemcu-dht/files/14054295/NodeMcuDht.zip)