GithubHelp home page GithubHelp logo

danielfaust / simpledht Goto Github PK

View Code? Open in Web Editor NEW

This project forked from winlinvip/simpledht

0.0 1.0 0.0 35 KB

Simple, Stable and Fast Arduino Temp & Humidity Sensors for DHT11 and DHT22. http://learn.adafruit.com/dht

License: MIT License

C++ 100.00%

simpledht's Introduction

SimpleDHT

Simple, Stable and Fast Arduino Temp & Humidity Sensors for DHT11 and DHT22.

  1. Simple: Simple C++ code with lots of comments.
  2. Stable: Strictly follow the standard DHT protocol.
  3. Fast: Support 0.5HZ(DHT22) or 1HZ(DHT11) sampling rate.

Usage

To use this library:

  1. Download the zip from specified version: https://github.com/winlinvip/SimpleDHT/releases
  2. Import to Arduino: Arduino => Sketch => Include Library => Add .ZIP Library...
  3. Open example: Arduino => File => Examples => SimpleDHT => DHT11Default
  4. Connect the DHT11 and Upload program to Arduino.
  5. Open the Serial Window of Arduino IDE, we got the result as following.
=================================
Sample DHT11...
Sample OK: 19 *C, 31 H
=================================
Sample DHT11...
Sample OK: 19 *C, 31 H
=================================

Remark: For DHT11, no more than 1 Hz sampling rate (once every second).

Remark: For DHT22, no more than 0.5 Hz sampling rate (once every 2 seconds).

Sensors

Examples

This library including the following examples:

  1. DHT11Default: Use DHT11 to sample.
  2. DHT11WithRawBits: Use DHT11 to sample and get the 40bits RAW data.
  3. DHT11ErrCount: Use DHT11 to sample and stat the success rate.
  4. DHT22Default: Use DHT22 to sample.
  5. DHT22WithRawBits: Use DHT22 to sample and get the 40bits RAW data.
  6. DHT22Integer: Use DHT22 to sample and ignore the fractional data.
  7. DHT22ErrCount: Use DHT22 to sample and stat the success rate.
  8. TwoSensorsDefault: Use two DHT11 to sample.

Links

  1. adafruit/DHT-sensor-library
  2. Arduino #4469: Add SimpleDHT library.
  3. DHT11 datasheet and protocol.
  4. DHT22 datasheet and protoocl.

Winlin 2016.1

simpledht's People

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.