Giter Site home page Giter Site logo

temperaturemonitoringadafruit's Introduction

DHT11 Sensor Data Publisher to Adafruit IO

This Arduino project transmits temperature and humidity readings from a DHT11 sensor to Adafruit IO using WiFi and MQTT communication.

Features:

  • Connects to a WiFi network.
  • Reads temperature and humidity data from a DHT11 sensor.
  • Publishes the sensor readings to designated feeds (Temperature and Humidity) on your Adafruit IO account.
  • Provides feedback on connection status and data publishing success/failure via the serial monitor.

Hardware Requirements:

  • Arduino Uno or compatible board
  • DHT11 temperature and humidity sensor
  • WiFi module (if not built-in)
  • Breadboard and jumper wires

Software Requirements:

Installation:

  1. Download and install the Arduino IDE.
  2. Install the required libraries (Adafruit_MQTT and SimpleDHT) using the Library Manager in the Arduino IDE (Sketch -> Include Library -> Manage Libraries).
  3. Replace the placeholder values in the code:
    • SSID and PASS: Your WiFi network name and password.
    • USERNAME and KEY: Your Adafruit IO username and AIO key (obtainable from your Adafruit IO account).
  4. Connect your DHT11 sensor and other hardware components according to your specific circuit.
  5. Upload the code to your Arduino board.

Usage:

  1. Open the serial monitor in the Arduino IDE (Tools -> Serial Monitor) at 115200 baud.
  2. You'll see messages indicating connection attempts and status.
  3. Once connected, the program will display temperature (°C) and humidity (%) readings every 5 seconds (adjustable in the code).
  4. If publishing is successful, "Sent!" messages will appear on the serial monitor.

Additional Notes:

  • The code includes error handling for connection attempts.
  • Consider using float data types for temperature and humidity to store more precise values.
  • Adjust the delay in the loop function based on your desired data update frequency.
  • Explore the Adafruit IO dashboard to visualize the published sensor data.

This project provides a basic example of using an Arduino to collect sensor data and send it to the cloud using Adafruit IO. You can extend this project by adding features like:

  • Logging data to an SD card.
  • Sending push notifications based on sensor readings.
  • Controlling external devices based on sensor data.

temperaturemonitoringadafruit's People

Contributors

vipinmishra0852 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.