temphum9 2.0.0.0

Functions

void temphum9_cfg_setup (temphum9_cfg_t *cfg)
 Config Object Initialization function.
 
err_t temphum9_init (temphum9_t *ctx, temphum9_cfg_t *cfg)
 Initialization function.
 
void temphum9_read_register (temphum9_t *ctx, uint16_t address, uint8_t num_data, uint16_t *data_out)
 Readinig register content.
 
void temphum9_send_command (temphum9_t *ctx, uint16_t command)
 Issuing a command.
 
float temphum9_get_temperature (temphum9_t *ctx, uint8_t data_mode)
 Calculating temperature.
 
float temphum9_get_humidity (temphum9_t *ctx, uint8_t data_mode)
 Calculating relative humidity.
 
void temhum9_get_data (temphum9_t *ctx, uint8_t data_mode, float *temp, float *hum)
 Calculating temperature and relative humidity.
 

Detailed Description

Function Documentation

◆ temhum9_get_data()

void temhum9_get_data ( temphum9_t * ctx,
uint8_t data_mode,
float * temp,
float * hum )

Calculating temperature and relative humidity.

Parameters
ctxClick object.
data_modemode to be used for measurement (normal or low power mode)
temptemperature measurement data
humrelative humidity measurement data

This function performs temperature and relative humidity measurement and calculates temperature and relative humidity

◆ temphum9_cfg_setup()

void temphum9_cfg_setup ( temphum9_cfg_t * cfg)

Config Object Initialization function.

Parameters
cfgClick configuration structure.

This function initializes click configuration structure to init state.

Note
All used pins will be set to unconnected state.

◆ temphum9_get_humidity()

float temphum9_get_humidity ( temphum9_t * ctx,
uint8_t data_mode )

Calculating relative humidity.

Parameters
ctxClick object.
data_modemode to be used for measurement (normal or low power mode)

This function performs relative humidity measurement and calculates relative humidity

◆ temphum9_get_temperature()

float temphum9_get_temperature ( temphum9_t * ctx,
uint8_t data_mode )

Calculating temperature.

Parameters
ctxClick object.
data_modemode to be used for measurement (normal or low power mode)

This function performs temperature measurement and calculates temperature

◆ temphum9_init()

err_t temphum9_init ( temphum9_t * ctx,
temphum9_cfg_t * cfg )

Initialization function.

Parameters
ctxClick object.
cfgClick configuration structure.

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

◆ temphum9_read_register()

void temphum9_read_register ( temphum9_t * ctx,
uint16_t address,
uint8_t num_data,
uint16_t * data_out )

Readinig register content.

Parameters
ctxClick object.
addressAddress of a register to read (command)
num_datasingle for one 16-bit register or dual for two 16-bit registers
data_outread data is stored into this array

This function reads one or two 16-bit registers

◆ temphum9_send_command()

void temphum9_send_command ( temphum9_t * ctx,
uint16_t command )

Issuing a command.

Parameters
ctxClick object.
commandcommand to be sent to device

This function issues (sends) command to device