2016-05-10 17:09:28 +08:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2016 Intel Corporation
|
|
|
|
*
|
2017-01-19 09:01:01 +08:00
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
2016-05-10 17:09:28 +08:00
|
|
|
*/
|
|
|
|
|
2018-09-15 01:43:44 +08:00
|
|
|
#ifndef ZEPHYR_DRIVERS_SENSOR_DHT_DHT_H_
|
|
|
|
#define ZEPHYR_DRIVERS_SENSOR_DHT_DHT_H_
|
2016-05-10 17:09:28 +08:00
|
|
|
|
|
|
|
#include <device.h>
|
|
|
|
|
|
|
|
#define DHT_START_SIGNAL_DURATION 18000
|
|
|
|
#define DHT_SIGNAL_MAX_WAIT_DURATION 100
|
|
|
|
#define DHT_DATA_BITS_NUM 40
|
|
|
|
|
|
|
|
struct dht_data {
|
|
|
|
struct device *gpio;
|
2017-04-21 23:03:20 +08:00
|
|
|
u8_t sample[4];
|
2016-05-10 17:09:28 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|