39#ifdef PREINIT_SUPPORTED
43#ifdef MikroCCoreVersion
44 #if MikroCCoreVersion >= 1
49#include "drv_digital_out.h"
50#include "drv_digital_in.h"
67#define DHT22_RESP_NOT_READY 0
68#define DHT22_RESP_READY 1
86#define DHT22_MAP_MIKROBUS( cfg, mikrobus ) \
87 cfg.sd1 = MIKROBUS( mikrobus, MIKROBUS_CS ); \
88 cfg.sd2 = MIKROBUS( mikrobus, MIKROBUS_INT )
dht22_return_value_t
DHT22 Click return value data.
Definition dht22.h:144
@ DHT22_OK
Definition dht22.h:145
@ DHT22_ERROR
Definition dht22.h:146
dht22_sda_sel_t
DHT22 Click data pin selector.
Definition dht22.h:99
@ DHT22_SDA_SEL_SDA2
Definition dht22.h:101
@ DHT22_SDA_SEL_SDA1
Definition dht22.h:100
err_t dht22_start_signal(dht22_t *ctx)
DHT22 sends start signal to the sensor function.
err_t dht22_get_measurement_data(dht22_t *ctx, float *humidity, float *temperature)
DHT22 get measurement data from the sensor function.
err_t dht22_init_sda_input(dht22_t *ctx)
DHT22 init SDA data pin as input function.
err_t dht22_init(dht22_t *ctx, dht22_cfg_t *cfg)
DHT22 initialization function.
err_t dht22_init_sda_output(dht22_t *ctx)
DHT22 init SDA data pin as output function.
err_t dht22_check_sensor_response(dht22_t *ctx)
DHT22 release the bus to wait the sensor response signal function.
void dht22_cfg_setup(dht22_cfg_t *cfg)
DHT22 configuration object setup function.
err_t dht22_get_sensor_data(dht22_t *ctx, uint16_t *hum_data, uint16_t *temp_data)
DHT22 reading data from the sensor function.
Click configuration structure definition.
Definition dht22.h:128
pin_name_t sd2
Definition dht22.h:132
pin_name_t sd1
Definition dht22.h:131
dht22_sda_sel_t sda_sel
Definition dht22.h:134
Click ctx object definition.
Definition dht22.h:109
err_t sda_out_stat
Definition dht22.h:119
err_t sda_in_stat
Definition dht22.h:120
pin_name_t sd2
Definition dht22.h:115
digital_in_t sda_in
Definition dht22.h:112
pin_name_t sd1
Definition dht22.h:114
digital_out_t sda_out
Definition dht22.h:110
dht22_sda_sel_t sda_sel
Definition dht22.h:117