This project consist of Arduino board, serial TFT LCD 128×160 display, DHT22 sensor and obviously bread board and jumpwires.
- Temperature measurements : -40 – 125° C, +/- 0.2° C
- Humidity measurements : 0 – 100% , +/- 5 %
- Update rate 2 s
- Humidex(“describe how hot the weather feels to the average person, by combining the effect of heat and humidity.” ) is calculated based on measurements
- Humidex digits color varies and represents affect on humans.
- Black and white display themes.
TFT serial LCD display (ST7735 controller)
I used 128×160 resolution display from ICStation. It comes as module ready for mounting on a bread board and also have SD card slot.
Connecting the display to Arduino is quite tricky, but there is table for that is you are using Adafruit LCD and GFX libraries.
|LCD module pin||Arduino pin||Comments|
|6 (Reset)||8||Changeable via code. (Can be connected to Arduino hardware reset pin or +3,3V)|
|7 (A0)||9||Changeable via code|
|8 (SDA)||51 (MOSI)||Pin number depends on Arduino board|
|9 (SCK)||52 (SCK)||Pin number depends on Arduino board|
|10 (CS)||10||Changeable via code|
|15 (LED+)||+ 3,3 V|
You may notice that GND and VCC pins on LCD board is not connected, with them connected LCD tends to blink when contents are updated.
Temperature and humidity sensor is connected that way:
|1 (VCC)||+3,3 V|
|2 (DATA)||7||Changeable via code|
Picture after connections:
Program uses DHT22, LCD, GFX libraries from Adafruit. Don’t recommend use any other libraries for DHT22 sensor because it may give not correct reading at the temperatures below zero.
Humidex calculated by method presented there and color representation is from meteo.lt.
Project code is hosted on github.
Project demo video: