airquality 2.0.0.0
airquality.h File Reference

This file contains API for Air quality Click Driver. More...

#include "drv_analog_in.h"

Go to the source code of this file.

Data Structures

struct  airquality_t
 Air quality Click context object. More...
 
struct  airquality_cfg_t
 Air quality Click configuration object. More...
 

Macros

#define AIRQUALITY_MAP_MIKROBUS(cfg, mikrobus)    cfg.an = MIKROBUS( mikrobus, MIKROBUS_AN ); \
 MikroBUS pin mapping.
 

Enumerations

enum  airquality_return_value_t { AIRQUALITY_OK = 0 , AIRQUALITY_ERROR = -1 }
 Air quality Click return value data. More...
 

Functions

void airquality_cfg_setup (airquality_cfg_t *cfg)
 Air quality configuration object setup function.
 
err_t airquality_init (airquality_t *ctx, airquality_cfg_t *cfg)
 Air quality initialization function.
 
err_t airquality_read_an_pin_value (airquality_t *ctx, uint16_t *data_out)
 Air quality read AN pin value function.
 
err_t airquality_read_an_pin_voltage (airquality_t *ctx, float *data_out)
 Air quality read AN pin voltage level function.
 

Detailed Description

This file contains API for Air quality Click Driver.

Enumeration Type Documentation

◆ airquality_return_value_t

Air quality Click return value data.

Predefined enum values for driver return values.

Enumerator
AIRQUALITY_OK 
AIRQUALITY_ERROR