hallcurrent12
2.0.0.0
|
API for configuring and manipulating Hall Current 12 Click driver. More...
Modules | |
Hall Current 12 Registers Settings | |
Settings for registers of Hall Current 12 Click driver. | |
Macros | |
#define | HALLCURRENT12_SET_DEV_ADDR 0x4D |
Hall Current 12 device address setting. More... | |
Functions | |
void | hallcurrent12_cfg_setup (hallcurrent12_cfg_t *cfg) |
Hall Current 12 configuration object setup function. More... | |
err_t | hallcurrent12_init (hallcurrent12_t *ctx, hallcurrent12_cfg_t *cfg) |
Hall Current 12 initialization function. More... | |
err_t | hallcurrent12_default_cfg (hallcurrent12_t *ctx) |
Hall Current 12 default configuration function. More... | |
err_t | hallcurrent12_get_adc (hallcurrent12_t *ctx, uint16_t *data_out) |
Hall Current 12 get ADC function. More... | |
err_t | hallcurrent12_get_adc_voltage (hallcurrent12_t *ctx, float *adc_vtg) |
Hall Current 12 get ADC voltage function. More... | |
err_t | hallcurrent12_get_current (hallcurrent12_t *ctx, float *current) |
Hall Current 12 get current function. More... | |
err_t | hallcurrent12_read_an_pin_voltage (hallcurrent12_t *ctx, float *data_out) |
Hall Current 12 read AN pin voltage level function. More... | |
API for configuring and manipulating Hall Current 12 Click driver.
#define HALLCURRENT12_SET_DEV_ADDR 0x4D |
Hall Current 12 device address setting.
Specified setting for device slave address selection of Hall Current 12 Click driver.
void hallcurrent12_cfg_setup | ( | hallcurrent12_cfg_t * | cfg | ) |
Hall Current 12 configuration object setup function.
This function initializes click configuration structure to initial values.
[out] | cfg | : Click configuration structure. See hallcurrent12_cfg_t object definition for detailed explanation. |
err_t hallcurrent12_default_cfg | ( | hallcurrent12_t * | ctx | ) |
Hall Current 12 default configuration function.
This function executes a default configuration of Hall Current 12 click board.
[in] | ctx | : Click context object. See hallcurrent12_t object definition for detailed explanation. |
0
- Success, -1
- Error.err_t hallcurrent12_get_adc | ( | hallcurrent12_t * | ctx, |
uint16_t * | data_out | ||
) |
Hall Current 12 get ADC function.
This function reads 12-bit ADC data of the TMCS1100 1% High-Precision, Basic Isolation Hall-Effect Current Sensor on the Hall Current 12 click boardâ„¢.
[in] | ctx | : Click context object. See hallcurrent12_t object definition for detailed explanation. |
[out] | data_out | : Output ADC result. |
0
- Success, -1
- Error.err_t hallcurrent12_get_adc_voltage | ( | hallcurrent12_t * | ctx, |
float * | adc_vtg | ||
) |
Hall Current 12 get ADC voltage function.
This function reads 12-bit ADC data and calculate ADC voltage ( V ) of the TMCS1100 1% High-Precision, Basic Isolation Hall-Effect Current Sensor on the Hall Current 12 click boardâ„¢.
[in] | ctx | : Click context object. See hallcurrent12_t object definition for detailed explanation. |
[out] | adc_vtg | : Output ADC voltage ( V ) data. |
0
- Success, -1
- Error.err_t hallcurrent12_get_current | ( | hallcurrent12_t * | ctx, |
float * | current | ||
) |
Hall Current 12 get current function.
This function reads 12-bit ADC data and calculate current ( A ) of the TMCS1100 1% High-Precision, Basic Isolation Hall-Effect Current Sensor on the Hall Current 12 click boardâ„¢.
[in] | ctx | : Click context object. See hallcurrent12_t object definition for detailed explanation. |
[out] | adc_vtg | : Output current ( A ) data. |
0
- Success, -1
- Error.err_t hallcurrent12_init | ( | hallcurrent12_t * | ctx, |
hallcurrent12_cfg_t * | cfg | ||
) |
Hall Current 12 initialization function.
This function initializes all necessary pins and peripherals used for this click board.
[out] | ctx | : Click context object. See hallcurrent12_t object definition for detailed explanation. |
[in] | cfg | : Click configuration structure. See hallcurrent12_cfg_t object definition for detailed explanation. |
0
- Success, -1
- Error.err_t hallcurrent12_read_an_pin_voltage | ( | hallcurrent12_t * | ctx, |
float * | data_out | ||
) |
Hall Current 12 read AN pin voltage level function.
This function reads results of AD conversion of the AN pin and converts them to proportional voltage level.
[in] | ctx | : Click context object. See hallcurrent12_t object definition for detailed explanation. |
[out] | data_out | : Output voltage level of the analog pin ( V ). |
0
- Success, -1
- Error.