you can configure DHT type
This commit is contained in:
parent
a68a207fa1
commit
d3d7e0318a
@ -50,3 +50,7 @@
|
|||||||
#ifndef CONFIG_SETUP_GPIO
|
#ifndef CONFIG_SETUP_GPIO
|
||||||
#define CONFIG_SETUP_GPIO 3
|
#define CONFIG_SETUP_GPIO 3
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef CONFIG_DHT_TYPE
|
||||||
|
#define CONFIG_DHT_TYPE DHT11
|
||||||
|
#endif
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#ifdef CONFIG_ENABLE_DHT
|
#ifdef CONFIG_ENABLE_DHT
|
||||||
#include <DHT.h>
|
#include <DHT.h>
|
||||||
#define DHTTYPE DHT11
|
#define DHTTYPE CONFIG_DHT_TYPE
|
||||||
DHT *dht = NULL;
|
DHT *dht = NULL;
|
||||||
int DHTSetup(int pin);
|
int DHTSetup(int pin);
|
||||||
int DHTGetTempAndHumidity(float &t, float &h);
|
int DHTGetTempAndHumidity(float &t, float &h);
|
||||||
|
Loading…
Reference in New Issue
Block a user