Introduction
In this article, I am going to explain about controlling a greenhouse with the help of Arduino. From this, I am going to check the temperature and humidity in the greenhouse.
What is a green house?
- Green house is a glass based structure or roof made of transperent material. In this greenhouse, we can plant vegatables and flowers naturally. There are installations, heating, cooling, lighting, etc. with which we can monitor the greenhouse by the computer to optimize the conditions for plant growth.
Figure1 - GreenHouse.
Parts Of Lists
- Arduino Uno
- Relays
- DHT11 Sensor [Temperature+Humidity sensor]
- LCD
- Hook Wires
- Bread Board.
Parts Explanation
Relay
- The relay is simply an act as the switch, so we can use the relay as the electrical applicance for the circuit.
Figure2 - Relay Box
DHT11 Sensor
DHT11 is the known combination of temperature sensor and humidity sensor.
Temperature sensor
- It is used to measure the amount of heat energy or even coldness.
- It may be used to detect in the analog and digital output.
Humidity sensor
- It is a sensor, which is used to sense and measure the percentage of the humidity in the air.
- It can also measure air temperature.
- Humidity sensor is used for capacative measurement.
- These voltages are the changes, which are converted into digital reading.
Figure3 - DHT11 Sensor.
LCD Display
- LCD is Liquid Crystal Display (LCD).
- It can have the flat-panel or the electronic display.
- It is used in the hospital, showrooms, buses, railway station, airport etc.
Figure4 - LCD Display.
Connection
Step 1
DTH11 Sensor To Arduino Uno
- Connect the V to the 5v of the Arduino Uno.
- Connect the G to the Gnd of the of the Arduino uno.
- Connect the S to the any input pin of the digital side as u like.
Step 2
LCD Display to Arduino Uno
- Fix the LCD in the 16 to 2 in the bread board.
- The 16 pin to the Gnd
- The 15 pin to the Vcc
- The 14 pin to the Digital pin 02
- The 13 pin to the Digital pin 03
- The 12 pin to the Digital pin 04
- The 11 pin to the Digital pin 05
- The 01 pin to the Gnd.
- The 02 pin to the Vcc.
- The 03 pin to the potentiometer.
- The 04 pin to the Digital pin 07.
- The 05 pin to the Gnd.
- The 06 pin to the Digital pin 06.
Programming
- #include "DHT.h"
-
- #define DHTPIN 2
-
- #define DHTTYPE DHT22 // DHT 22 (AM2302)
-
- void setup() {
- Serial.begin(9600);
- Serial.println("DHTxx test!");
-
- dht.begin();
- }
-
- void loop() {
-
- delay(2000);
-
- float h = dht.readHumidity();
-
- float t = dht.readTemperature();
-
- float f = dht.readTemperature(true);
- if (isnan(h) || isnan(t) || isnan(f)) {
- Serial.println("Failed to read from DHT sensor!");
- return;
- }
-
-
- float hi = dht.computeHeatIndex(f, h);
-
- Serial.print("Humidity: ");
- Serial.print(h);
- Serial.print(" %\t");
- Serial.print("Temperature: ");
- Serial.print(t);
- Serial.print(" *C ");
- Serial.print(f);
- Serial.print(" *F\t");
- Serial.print("Heat index: ");
- Serial.print(hi);
- Serial.println(" *F");
- }
Explanation
- In this article, I explained the control of the green house effect in the Arduino Uno. It will detect the temperature at the greenhouse in the LCD display. From this, we can monitor the temperature by using the DTH11 sensor in the greenhouse, if the temperature and humidity is not in good condition, it will display in the LCD display.
Output
Figure5 - LCD Display