26 lines
332 B
C
26 lines
332 B
C
#ifndef dht22_H
|
|
#define dht22_H
|
|
|
|
#include <stdint.h>
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
typedef struct {
|
|
int pin;
|
|
float humidity;
|
|
float temperature;
|
|
} sensor;
|
|
|
|
void getData(sensor *s);
|
|
//static int read_dht22_dat(int pin, sensor *s);
|
|
//static uint8_t sizecvt(const int read);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
|
|
#endif
|