adc2 2.0.0.0
Public function

Functions

void adc2_cfg_setup (adc2_cfg_t *cfg)
 Config Object Initialization function.
 
ADC2_RETVAL adc2_init (adc2_t *ctx, adc2_cfg_t *cfg)
 Initialization function.
 
float adc2_read_adc_data (adc2_t *ctx)
 Read adc data function.
 
void adc2_set_vref (adc2_t *ctx, float vref)
 Setting reference voltage.
 

Detailed Description

Function Documentation

◆ adc2_cfg_setup()

void adc2_cfg_setup ( adc2_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.

◆ adc2_init()

ADC2_RETVAL adc2_init ( adc2_t * ctx,
adc2_cfg_t * cfg )

Initialization function.

Parameters
ctxClick object.
cfgClick configuration structure.

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

◆ adc2_read_adc_data()

float adc2_read_adc_data ( adc2_t * ctx)

Read adc data function.

Parameters
ctxClick object.
Returns
Reading 3 bytes from Click board and returning it in one variable

@description Function is used to read 3 bytes from ADC convertor.

◆ adc2_set_vref()

void adc2_set_vref ( adc2_t * ctx,
float vref )

Setting reference voltage.

Parameters
ctxClick object.
vrefReference mV.

@description Function is used to set reference voltage.