How to Make an Arduino Weather Station

Introduction: How to Make an Arduino Weather Station

In this project, we will be making a weather station that measures temperature and air humidity using Arduino which displays the value of current temperature and humidity on an LCD Display

Step 1: Components Required

Step 2: Circuit Connection

Here is the full pin connections list:-

LCD Connection:-

LCD PIN 1------------GND

LCD PIN 2------------VCC

LCD PIN 3------------Middle pin of the pot

LCD PIN 4------------D12 of arduino

LCD PIN 5------------GND

LCD PIN 6------------D11 of arduino

LCD PIN 7------------NC

LCD PIN 8------------NC

LCD PIN 9------------NC

LCD PIN 10----------NC

LCD PIN 11----------D5 of arduino

LCD PIN 12----------D4 of arduino

LCD PIN 13----------D3 of arduino

LCD PIN 14----------D2 of arduino

LCD PIN 15----------VCC

LCD PIN 16----------GND

DHT 22 Connection:-

VCC----------- +5V

GND-----------GND

DATA---------Arduino pin 8

Step 3: Code

#include <LiquidCrystal.h>
#include "DHT.h"
#define DHTPin 8
LiquidCrystal lcd(12,11,5,4,3,2);
DHT dht;</liquidcrystal.h></p><p>void setup()
{
  dht.setup(DHTPin); 
  lcd.begin(16,2);
}
void loop()
{
  float temp = dht.getTemperature();
 float humi = dht.getHumidity();
 lcd.setCursor(0,0);
 lcd.print("Temp: ");
 lcd.print(temp);
 lcd.print(" C");
 lcd.setCursor(0,1);
 lcd.print("Humi: ");
 lcd.print(humi);
 lcd.print(" %");
 delay(2000);
}</p>

Step 4: Conclusion

Hope I have given you everything you need to make this project yourself.If you like my project then please consider subscribing me on youtube..Thank you for your time.

https://www.youtube.com/creativestuff

Be the First to Share

    Recommendations

    • CNC and 3D Printing Contest

      CNC and 3D Printing Contest
    • Puzzles Challenge

      Puzzles Challenge
    • Rice & Grains Challenge

      Rice & Grains Challenge

    2 Comments

    0
    Paul Mawhorter
    Paul Mawhorter

    2 months ago

    This Arduino code has a number of problems. If you just copy it into the Arduino IDE and upload it to the Arduino it will not work. Here is the updated code:

    #include <DHT.h>
    #include <LiquidCrystal.h>
    #define DHTPIN 8
    #define DHTTYPE DHT22
    LiquidCrystal lcd(12,11,10,5,4,3,2);
    DHT dht(DHTPIN, DHTTYPE);
    void setup() {
    dht.begin();
    lcd.begin(16,2);

    }

    void loop() {
    delay(2000);
    float temp = dht.readTemperature();
    float humi = dht.readHumidity();
    lcd.setCursor(0,0);
    lcd.print("Temp: ");
    lcd.print(temp);
    lcd.print(" C");
    lcd.setCursor(0,1);
    lcd.print("Humi:");
    lcd.print(humi);
    lcd.print(" %");
    delay(2000);

    }

    0
    Lindy
    Lindy

    Question 11 months ago

    Is this the full coding for this project