mirror of
https://github.com/RobTillaart/Arduino.git
synced 2024-10-03 18:09:02 -04:00
0.3.3 DHT12
This commit is contained in:
parent
ccdf651a18
commit
471b9c5936
@ -1,3 +1,18 @@
|
||||
platforms:
|
||||
rpipico:
|
||||
board: rp2040:rp2040:rpipico
|
||||
package: rp2040:rp2040
|
||||
gcc:
|
||||
features:
|
||||
defines:
|
||||
- ARDUINO_ARCH_RP2040
|
||||
warnings:
|
||||
flags:
|
||||
|
||||
packages:
|
||||
rp2040:rp2040:
|
||||
url: https://github.com/earlephilhower/arduino-pico/releases/download/global/package_rp2040_index.json
|
||||
|
||||
compile:
|
||||
# Choosing to run compilation tests on 2 different Arduino platforms
|
||||
platforms:
|
||||
@ -7,5 +22,7 @@ compile:
|
||||
# - leonardo
|
||||
- m4
|
||||
- esp32
|
||||
# - esp8266
|
||||
# - mega2560
|
||||
- esp8266
|
||||
# - mega2560
|
||||
- rpipico
|
||||
|
||||
|
48
libraries/DHT12/CHANGELOG.md
Normal file
48
libraries/DHT12/CHANGELOG.md
Normal file
@ -0,0 +1,48 @@
|
||||
# Change Log DHT12
|
||||
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
The format is based on [Keep a Changelog](http://keepachangelog.com/)
|
||||
and this project adheres to [Semantic Versioning](http://semver.org/).
|
||||
|
||||
|
||||
## [0.3.3] - 2022-11-01
|
||||
- add changelog.md
|
||||
- add rp2040 to build-CI
|
||||
|
||||
|
||||
## [0.3.2] - 2021-12-16
|
||||
- update library.json
|
||||
- update license
|
||||
- add isConnected()
|
||||
|
||||
## [0.3.1] - 2021-10-25
|
||||
- add lastRead()
|
||||
- update Arduino-CI
|
||||
- add badges
|
||||
|
||||
## [0.3.0] - 2020-12-19
|
||||
- add Arduino-CI + unit test
|
||||
- temperature and humidity made private
|
||||
|
||||
----
|
||||
|
||||
## [0.2.1] - 2020-06-07
|
||||
- fix library.json
|
||||
|
||||
## [0.2.0] - 2020-04-11
|
||||
- explicit constructors, select other Wire interface,
|
||||
- #pragma once
|
||||
|
||||
----
|
||||
|
||||
## [0.1.2] - 2018-09-02
|
||||
- fix negative temperature DHT12 - issue #111
|
||||
|
||||
## [0.1.1] - 2017-12-19
|
||||
- added ESP8266 - issue #86
|
||||
- Verified by Viktor Balint
|
||||
|
||||
## [0.1.0] - 2017-12-11
|
||||
- initial version
|
||||
|
@ -1,22 +1,10 @@
|
||||
//
|
||||
// FILE: DHT12.cpp
|
||||
// AUTHOR: Rob Tillaart
|
||||
// VERSION: 0.3.2
|
||||
// VERSION: 0.3.3
|
||||
// PURPOSE: I2C library for DHT12 for Arduino.
|
||||
//
|
||||
// HISTORY:
|
||||
// 0.1.0 2017-12-11 initial version
|
||||
// 0.1.1 2017-12-19 added ESP8266 - issue #86
|
||||
// Verified by Viktor Balint
|
||||
// 0.1.2 2018-09-02 fix negative temperature DHT12 - issue #111
|
||||
// 0.2.0 2020-04-11 explicit constructors, select other Wire interface,
|
||||
// #pragma once
|
||||
// 0.2.1 2020-06-07 fix library.json
|
||||
// 0.3.0 2020-12-19 add Arduino-CI + unit test
|
||||
// temperature and humidity made private
|
||||
// 0.3.1 2021-10-25 add lastRead, update Arduino-CI, badges
|
||||
// 0.3.2 2021-12-16 update library.json, license
|
||||
// add isConnected()
|
||||
// HISTORY: see changelog.md
|
||||
|
||||
|
||||
#include "DHT12.h"
|
||||
|
@ -3,7 +3,7 @@
|
||||
// FILE: DHT12.h
|
||||
// AUTHOR: Rob Tillaart
|
||||
// PURPOSE: DHT_I2C library for Arduino .
|
||||
// VERSION: 0.3.2
|
||||
// VERSION: 0.3.3
|
||||
// HISTORY: See DHT12.cpp
|
||||
// URL: https://github.com/RobTillaart/DHT12
|
||||
//
|
||||
@ -12,7 +12,7 @@
|
||||
#include "Arduino.h"
|
||||
#include "Wire.h"
|
||||
|
||||
#define DHT12_LIB_VERSION (F("0.3.2"))
|
||||
#define DHT12_LIB_VERSION (F("0.3.3"))
|
||||
|
||||
#define DHT12_OK 0
|
||||
#define DHT12_ERROR_CHECKSUM -10
|
||||
@ -23,7 +23,7 @@
|
||||
class DHT12
|
||||
{
|
||||
public:
|
||||
DHT12(TwoWire *wire); // to be tested explicitly
|
||||
DHT12(TwoWire *wire); // to be tested explicitly
|
||||
|
||||
#if defined(ESP8266) || defined(ESP32)
|
||||
bool begin(const uint8_t dataPin, const uint8_t clockPin);
|
||||
@ -36,7 +36,7 @@ public:
|
||||
float getHumidity() { return _humidity + _humOffset; };
|
||||
float getTemperature() { return _temperature + _tempOffset; };
|
||||
|
||||
// allows 1st order calibration
|
||||
// allows 1st order calibration
|
||||
void setHumOffset(float offset) { _humOffset = offset; };
|
||||
void setTempOffset(float offset) { _tempOffset = offset; };
|
||||
float getHumOffset() { return _humOffset; };
|
||||
|
@ -15,7 +15,7 @@
|
||||
"type": "git",
|
||||
"url": "https://github.com/RobTillaart/DHT12.git"
|
||||
},
|
||||
"version": "0.3.2",
|
||||
"version": "0.3.3",
|
||||
"license": "MIT",
|
||||
"frameworks": "arduino",
|
||||
"platforms": "*",
|
||||
|
@ -1,5 +1,5 @@
|
||||
name=DHT12
|
||||
version=0.3.2
|
||||
version=0.3.3
|
||||
author=Rob Tillaart <rob.tillaart@gmail.com>
|
||||
maintainer=Rob Tillaart <rob.tillaart@gmail.com>
|
||||
sentence=Arduino library for I2C DHT12 temperature and humidity sensor.
|
||||
|
Loading…
x
Reference in New Issue
Block a user