Make a Personal Weather Station

37,437

481

40

Published

Introduction: Make a Personal Weather Station

About: Check out my YouTube channel, for similar projects.

Sitting in your room you start sweating or feel chill; you wonder how much would be the temperature in your room? or what would be the humidity? This happened with me some time back.

This lead to inception of Personal Weather Station, that monitors temperature, humidity, pressure and light intensity of your room and uploads it to a private channel on thingspeak.com.

Let's get started.

Step 1: Quick Video

Here is a small video, that summaries every thing in 5 mins.

Click here to watch on youtube

Step 2: Electronics Components Needed for Personal Weather Station

Description: We will use DHT11 to sense humidity, BMP180 to sense temperature and pressure and a Light Dependent Resistor(LDR) to get rough idea of light intensity. Arduino nano will gather data from these sensors and send to ESP8266 for uploading it to your private channel on thingspeak.com. We will power our Arduino nano from a 12V-2A wall adapter, sensors and ESP8266 will receive down converted voltage from LM2596 based buck converter.

List of components:

  1. BMP180 pressure and temperature sensor,
  2. DHT11 humidity sensor,
  3. Light Dependent Resistor (LDR),
  4. ESP8266 wifi module(firmware ready),
  5. Arduino nano,
  6. 2 Resistors- 51 KOhm and 4.7KOhm,
  7. LM2596 buck converter,
  8. DC jack,
  9. Switch and
  10. 12V-2A wall adapter.

Step 3: Tools and Extra Items Needed for Personal Weather Station

Description: We will use wire stripper for stripping wire, file for smoothing cuts/holes on enclosure, glue gun for placing components inside enclosure, screw driver to close the enclosure lid and solder iron with solder wire to assemble circuit on general purpose circuit board(GCB). 4x4x2 inch plastic box acts as enclosure. We will also need male and female berg strip along with female connectors for proper assembly on GCB.

List of Tools:

  1. Wire stripper,
  2. File,
  3. Glue gun,
  4. Screw driver and
  5. Solder iron and solder wire.

List of Extra items:

  1. 4x4x2 inch plastic box (I used this dimension, any nearby dimensions should be fine),
  2. General purpose circuit board,
  3. male and female berg strip and
  4. female connectors.

Step 4: Software Requirements

Description: In order to see the value of sensor data, we will need a private channel on thingspeak.com. We will need Arduino IDEto write arduino code for arduino nano. (I assume that you guys are in possession of PC/laptop and a wifi route with access to internet)

List of software requirements:

  1. Private channel on Thingspeak.com and
  2. Arduino IDE (Preferably latest version).

You can download latest version of Arduino IDE from arduino.cc.

Now lets create a private channel on thingspeak.com.

Step 5: Creating Private Channel on Thingspeak.com

To make a private channel on thingspeak.com follow these steps:

  1. Open your web browser and go to thingspeak.com and click on 'Sign Up' tab in right top corner, (Image no.1)
  2. Fill in the details and click on 'Create account', (Image no.2)
  3. Now click on 'New Channel' tab, (Image no.3)
  4. Again fill in details for channel and enable 4 fields (as we will be sending 4 sensor values), scroll down and click on 'Save Channel' tab, (Image no.4/5)
  5. On this page click on 'API Keys' tab and note down your 'Write API Key'.

That's all folks, now you have your private thingspeak channel.

Now lets put all electronics component together.

Step 6: Schematic for Personal Weather Station

Here I am attaching image of schematic for Personal Weather Station. I am also attaching fritzing file for the same. Connections are fairly simple.

  1. BMP180 connects to I2C port of arduino nano.
  2. LDR is connected in voltage divider fashion with 51 KOhm resistor and junction is connects to A1 pin of arduino nano.
  3. DHT11's data pin is pulled high with 4.7 KOhm resistor and connected to A0 pin of arduino nano.
  4. ESP8266's TX and RX connects to D10 and D11 of arduino nano respectively. ESP8266's CH_PD connects to 3.3V rail.
  5. Adjust LM2596 module's output to 3.3V by turning potentiometer on this module. Connect output of this module to Vcc and Gnd of BMP180,DHT11,LDR and ESP8266's Vcc and Gnd respectively.
  6. Input of LM2596 module comes from 12V-2A wall adapter which also connects to Vin and Gnd of Arduino nano.

We need to assemble this circuit on General Purpose Circuit board. Lets do that.

Step 7: Assembling Circuit on General Purpose Circuit Board (GCB)

Hardware tools and extra items from step 3 are now in business.

  1. Use female berg strip for Arduino nano and ESP8288's placement on GCB,
  2. Use solder iron and solder wire to connect them electrically to the board,
  3. Use female connectors to extend the reach of all sensors and LM2596 module as they will be stuck to the lid and wall of enclosure,
  4. Use male berg strip to make connecting points for female extensions made in 3,
  5. Realize circuit schematic on GCB using wires (strip them using wire stripper), or rail of melted solder wire and finally,
  6. Check for sorts before powering the circuit using a multimeter.

Now that all hardware is placed on GCB, let's look at the code.

Step 8: Code

Code for Personal Weather Station is fairly simple. I have commented code properly for ease of portability. Before you burn the code take care of following things.

  1. Make sure that all libraries are installed,
  2. Replace hyphens with SSID of your access point (wifi router) in line 14 of the code,
  3. Replace hyphens with PASSWORD of your wifi network in line 15 of the code,
  4. Replace hyphens with your thingspeak's private channel write API key in line 17 and
  5. While programming Arduino nano make sure that your 12V DC supply is OFF.

Here is the link to github (Personal Weather Station) for downloading code and libraries that I used.

Now that we have our hardware and software in place, only thing remaining is packaging.

Step 9: Enclosure Preperation

Now we need to make holes of various shape and size on the 4x4x2 inch box. We need to make holes for DC jack and switch on any preferred wall of enclosure. We also need to make holes for sensors on the lid of enclosure.

I have attached an image showing the dimensions of the holes that we need to make on the enclosure.

Use hot blade to cut through the plastic.

Use file to smooth the holes.

Now your enclosure is prepared to host your circuit.

Step 10: Closing the Lid

Put your assembled GCB inside the enclosure.

Place switch and DC jack in the holes on the wall; sensors on the holes of the lid. Finalize their position and use glue gun to fix them. Finally use screw driver to close the lid.

There you have it, your Personal Weather Station. Turn on the power supply and see your room's temperature, humidity, pressure and light intensity from any where in the world through your smartphone/PC/Laptop/Tablet on your thingspeak private channel.

Thats all for this instructable. Comment in case of any doubt.

If you liked this instructables there is good chance that you will love my youtube channel. Thanks for reading.

Share

    Recommendations

    • Water Contest

      Water Contest
    • Oil Contest

      Oil Contest
    • Creative Misuse Contest

      Creative Misuse Contest

    40 Discussions

    Hello miniProjects,

    Thanks for your previous message. I got the power connected to both the rails and the Arduino is showing a powered connection from the buck converter. However, when I have the device powered it does not connect to my wifi network or output any data to ThingSpeak. Is there something I am missing or I need to do in order for it to work? Thank you!

    1 more answer

    can you please verify thay you have followed 8th step properly and used same esp firmware that I have in github link.

    Hello VictoryKing, I have been working on completing this project. However, with the breadboarding, I don't know how to connect it to the power source. How do you do the cross-connected wires for the buck converter to the power sourcing? I have attached images of what I have so far and It would be greatly appreciated if you could help. Thanks! :)

    IMG_0944.JPGIMG_0945.JPGIMG_0946.JPGIMG_0947.JPG
    1 more answer

    Hi,

    I didn't exactly understood what you meant by 'cross-connected wires for the buck converter'. Input side of buck converter connects to any 6-20v supply.

    One thing that might be causing issue in your case is that in breadboards upper rails are sorted in group of 5. I made a mistake in fritzing schematic for upper two rail I am sorry about that. If you notice lower rail i have two small red and black wires just above buck converter. You are missing that in your images. Do it for both upper and lower rails. that should provide power to all components.

    Hope that helps.

    Would this project work with Arduino Uno and would it be possible to add an LCD to display the sensor readings? Could you do the LCD with Arduino Uno or on Nano?

    2 replies

    It will work with arduino uno. LCD, I am not 100% sure but I have used OLEDs with arduino boards that can display why ever you want. Thanks.

    Thank you! I am building this project with a partner for my class project. I am excited to use your tutorial and build the weather station.

    Beautiful work. I keep imagining putting a servo to trigger the atmospheric pressure pointer, for example, giving more realism and precision to a old wall barometer.

    And by storing the parameter values every 15 minutes you could clearly see the pressure variation in the last 6, 12 or 24 hours for example at the push of a button.

    What do you think?

    1 reply

    Hello, My build won't connect to the internet although I have loaded the correct SSID and password. The serial monitor reports

    resetting esp8266

    OK not found

    connection closed

    I would be grateful for any help!

    I am getting error exit status 1.
    Pls help me. I have to submit my project on monday.

    Use firmware form https://github.com/jayraj4021/Personal-Weather-Station-14

    How to connect.
    How to program it?
    Using aurdino ide?
    Pls tell how to connect wifi module to computer?

    https://www.instructables.com/id/Intro-Esp-8266-firmware-update/

    My esp8826 is not connecting to wifi.

    0
    user
    Naevus

    1 year ago

    Arduino is excess. 8266 has enough power to pull the whole project and a lot more. For example look at the http://wifi-iot.com/?m=main

    3 replies

    Thanks for the feedback.

    I will definitely check out the link.

    I have the same project and Instructables, but at a different site. Unfortunately, not in English language. I wanted to do the translation for Instructables, but did not have time :) If it is interesting - you can see it through a translator:

    https://translate.google.com/translate?hl=ru&sl=ru...
    I will be happy you think about the project (and - is it necessary to translate it here?)

    Hey Naevus: I really like your version of the project, even reading it through google translate. There are parts that are perfectly clear and parts that are very, very funny (not your fault of course). I'm going to see what I can learn from your version. I agree that putting a Nano and an ESP together is overkill considering that the ESP is much more powerful. But maybe it made the project easier?