Humidity sensor with led alarm | Arduino project

This page contains Arduino Humidity sensor with led alarm source code. This project is good for someone who wants to make a humidity meter or hygrometer with led alarm if humidity and temperature over a threshold. It's easy to make and doesn't require an external power supply, just use power from an Arduino UNO R3 board (USB power compatible with this project).

Electronic components list:
1 x Arduino Uno R3
1x 20 x4 I2C LCD display
1 x AM 2320 humidity/temp sensor
1 x 5 mm led ( 2 x if you plan to use led for pin 13 instead built-in led)
1 x 1000 ohms resistor ( 2 x if you plan to use led for pin 13 instead built-in led)
Any USB power adapter, 500 mA current at least.

Here is the Arduino code:
AM 2320 library
LCD display i2c library

#include <Wire.h>
#include <AM2320.h>
#include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x3F, 20, 4);
AM2320 th;
int led2 = 12;

5 watts amplifier TDA7056A wiring diagram

TDA 7056 A is an audio power amplifier IC that has 5 watts output power with 8 ohms speaker and 3 watts with 16 ohms speaker.

The IC is simple to wiring and needs only 6 external components to make the amplifier working. TDA 7056A working with a power supply between 4.5 - 18 volts so the IC can use a battery as power supply. if you use more than 9 volts, you need to attach small heat sink to the IC.

TDA7056A has a built-in DC volume control so you can control the gain of the amplifier by changing voltage value at DC volume control pin by use a potentiometer. DC volume control makes you connect the audio signal directly to the amplifier input so it makes a sound more transparent and cleaner than a normal amplifier. 

The IC has a short circuit protection, over temperature protection, No switch-on/off clicks, ESD protected on all pins, Mute mode (The IC switch mode when DC volume control pin voltage lower than 0.3 volts) 

TDA 7056A has a very wide audio bandwidth 20 Hz to 300 KHz (Hi-fi amplifier standard frequency range = 20 Hz - 100 KHz).However, you need to keep every wire as short as possible to prevent AM frequency interfere.

Electronic components:

C1 = 1000 uf/16 volts

C2 = 0.1 uf/film capacitor
C3 = ceramic capacitor 103 or 1000 pf
C4 = 2.2 uf/ 16 volts (you can replace the ic with film capacitor if you want cleaner sound)
R1 = 1000 ohms
IC = TDA7056 A 
VR 1 = 100 Kilo-ohms potentiometer

Below picture is the circuit diagram

See TDA 7056A sound test video