accel22 2.0.0.0
|
This file contains API for Accel 22 Click Driver. More...
#include "drv_digital_out.h"
#include "drv_digital_in.h"
#include "drv_i2c_master.h"
#include "drv_spi_master.h"
#include "spi_specifics.h"
Go to the source code of this file.
Data Structures | |
struct | accel22_s |
Accel 22 Click context object. More... | |
struct | accel22_cfg_t |
Accel 22 Click configuration object. More... | |
struct | accel22_axes_t |
Accel 22 Click Axes data structure. More... | |
Typedefs | |
typedef err_t(* | accel22_master_io_t) (struct accel22_s *, uint8_t, uint8_t *, uint8_t) |
Accel 22 Click driver interface. | |
typedef struct accel22_s | accel22_t |
Accel 22 Click context object. | |
Enumerations | |
enum | accel22_drv_t { ACCEL22_DRV_SEL_SPI , ACCEL22_DRV_SEL_I2C } |
Accel 22 Click driver selector. More... | |
enum | accel22_range_t { ACCEL22_2G = 0x00 , ACCEL22_4G = 0x01 , ACCEL22_8G = 0x02 , ACCEL22_RANGE_BIT_MASK = 0xC0 } |
Accel 22 Click accel range selection. More... | |
enum | accel22_odr_t { ACCEL22_12p5HZ = 0x00 , ACCEL22_25HZ , ACCEL22_50HZ , ACCEL22_100HZ , ACCEL22_200HZ , ACCEL22_400HZ , ACCEL22_ODR_BIT_MASK = 0x07 } |
Accel 22 Click output data rate. More... | |
enum | accel22_return_value_t { ACCEL22_OK = 0 , ACCEL22_ERROR = -1 } |
Accel 22 Click return value data. More... | |
Functions | |
void | accel22_cfg_setup (accel22_cfg_t *cfg) |
Accel 22 configuration object setup function. | |
void | accel22_drv_interface_selection (accel22_cfg_t *cfg, accel22_drv_t drv_sel) |
Accel 22 driver interface setup function. | |
err_t | accel22_init (accel22_t *ctx, accel22_cfg_t *cfg) |
Accel 22 initialization function. | |
err_t | accel22_default_cfg (accel22_t *ctx) |
Accel 22 default configuration function. | |
err_t | accel22_generic_write (accel22_t *ctx, uint8_t reg, uint8_t *data_in, uint8_t len) |
Accel 22 data writing function. | |
err_t | accel22_generic_read (accel22_t *ctx, uint8_t reg, uint8_t *data_out, uint8_t len) |
Accel 22 data reading function. | |
err_t | accel22_write_register (accel22_t *ctx, uint8_t reg, uint8_t data_in) |
Accel 22 write register function. | |
err_t | accel22_read_register (accel22_t *ctx, uint8_t reg, uint8_t *data_out) |
Accel 22 read register function. | |
err_t | accel22_check_communication (accel22_t *ctx) |
Accel 22 check communication function. | |
uint8_t | accel22_get_int1_pin (accel22_t *ctx) |
Accel 22 get int1 pin function. | |
uint8_t | accel22_get_int2_pin (accel22_t *ctx) |
Accel 22 get int2 pin function. | |
err_t | accel22_set_filter_config (accel22_t *ctx, accel22_range_t range, accel22_odr_t odr) |
Accel 22 set filter config function. | |
err_t | accel22_get_axes (accel22_t *ctx, accel22_axes_t *axes) |
Accel 22 get axes function. | |
err_t | accel22_enable_temperature_measurement (accel22_t *ctx) |
Accel 22 enable temperature measurement function. | |
err_t | accel22_enable_adc_measurement (accel22_t *ctx) |
Accel 22 enable ADC measurement function. | |
err_t | accel22_calibrate_temperature (accel22_t *ctx, float room_temperature) |
Accel 22 calibrate temperature function. | |
err_t | accel22_get_temperature (accel22_t *ctx, float *temperature) |
Accel 22 get temperature function. | |
err_t | accel22_get_adc (accel22_t *ctx, float *v_adc) |
Accel 22 get adc function. | |
This file contains API for Accel 22 Click Driver.
typedef err_t(* accel22_master_io_t) (struct accel22_s *, uint8_t, uint8_t *, uint8_t) |
Accel 22 Click driver interface.
Definition of driver interface of Accel 22 Click driver. Driver serial interface.
Accel 22 Click context object.
Context object definition of Accel 22 Click driver.
enum accel22_drv_t |
enum accel22_odr_t |
enum accel22_range_t |