airquality2 2.0.0.0

Functions

void airquality2_cfg_setup (airquality2_cfg_t *cfg)
 Config Object Initialization function.
 
AIRQUALITY2_RETVAL airquality2_init (airquality2_t *ctx, airquality2_cfg_t *cfg)
 Initialization function.
 
void airquality2_generic_read (airquality2_t *ctx, uint8_t *data_buf, uint8_t len)
 Generic read function.
 
uint8_t airquality2_get_all_data (airquality2_t *ctx, uint16_t *value_co2, uint16_t *value_tvoc, int32_t *resistance)
 Read all data info function.
 

Detailed Description

Function Documentation

◆ airquality2_cfg_setup()

void airquality2_cfg_setup ( airquality2_cfg_t * cfg)

Config Object Initialization function.

Parameters
cfgClick configuration structure.

@description This function initializes click configuration structure to init state.

Note
All used pins will be set to unconnected state.

◆ airquality2_generic_read()

void airquality2_generic_read ( airquality2_t * ctx,
uint8_t * data_buf,
uint8_t len )

Generic read function.

Parameters
ctxClick object.
data_bufOutput data buf
lenNumber of the bytes to be read

@description This function reads data.

◆ airquality2_get_all_data()

uint8_t airquality2_get_all_data ( airquality2_t * ctx,
uint16_t * value_co2,
uint16_t * value_tvoc,
int32_t * resistance )

Read all data info function.

Parameters
ctxClick object.
value_co2Pointer to 16-bit Prediction Value CO2.
value_tvocPointer to 16-bit Prediction Value TVOC.
resistancePointer to 16-bit ( signed ) Resistance Value.

@description Reads all data information about the indoor air quality.

◆ airquality2_init()

AIRQUALITY2_RETVAL airquality2_init ( airquality2_t * ctx,
airquality2_cfg_t * cfg )

Initialization function.

Parameters
ctxClick object.
cfgClick configuration structure.

@description This function initializes all necessary pins and peripherals used for this click.