c6dofimu2 2.0.0.0
|
Functions | |
void | c6dofimu2_cfg_setup (c6dofimu2_cfg_t *cfg) |
Config Object Initialization function. | |
C6DOFIMU2_RETVAL | c6dofimu2_init (c6dofimu2_t *ctx, c6dofimu2_cfg_t *cfg) |
Initialization function. | |
void | c6dofimu2_default_cfg (c6dofimu2_t *ctx, c6dofimu2_cfg_t *cfg) |
Click Default Configuration function. | |
void | c6dofimu2_generic_write (c6dofimu2_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic write function. | |
void | c6dofimu2_generic_read (c6dofimu2_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic read function. | |
int16_t | c6dofimu2_get_axis (c6dofimu2_t *ctx, uint8_t adr_reg_low, uint8_t adr_reg_high) |
Low and high register data function. | |
void | c6dofimu2_read_accel (c6dofimu2_t *ctx, c6dofimu2_accel_data_t *accel_data) |
Read axis function. | |
void | c6dofimu2_read_gyro (c6dofimu2_t *ctx, c6dofimu2_gyro_data_t *gyro_data) |
Read axis function. | |
void c6dofimu2_cfg_setup | ( | c6dofimu2_cfg_t * | cfg | ) |
Config Object Initialization function.
cfg | Click configuration structure. |
@description This function initializes click configuration structure to init state.
void c6dofimu2_default_cfg | ( | c6dofimu2_t * | ctx, |
c6dofimu2_cfg_t * | cfg ) |
Click Default Configuration function.
ctx | Click object. |
cfg | Click configuration structure. |
@description This function executes default configuration for 6DOF IMU 2 click.
C6DOFIMU2_CFG_COMMAND -------------------------------------- C6DOFIMU2_ACCEL_NORMAL | C6DOFIMU2_GYRO_NORMAL
void c6dofimu2_generic_read | ( | c6dofimu2_t * | ctx, |
uint8_t | reg, | ||
uint8_t * | data_buf, | ||
uint8_t | len ) |
Generic read function.
ctx | Click object. |
reg | Register address. |
data_buf | Data buf to be written. |
len | Number of the bytes in data buf. |
@description This function reads data from the desired register.
void c6dofimu2_generic_write | ( | c6dofimu2_t * | ctx, |
uint8_t | reg, | ||
uint8_t * | data_buf, | ||
uint8_t | len ) |
Generic write function.
ctx | Click object. |
reg | Register address. |
data_buf | Output data buf |
len | Number of the bytes to be read |
@description This function writes data to the desired register.
int16_t c6dofimu2_get_axis | ( | c6dofimu2_t * | ctx, |
uint8_t | adr_reg_low, | ||
uint8_t | adr_reg_high ) |
Low and high register data function.
ctx | Click object. |
adr_reg_low | Low data register address. |
adr_reg_high | High data register address. |
@description This function get data from two BMI160 registers.
C6DOFIMU2_RETVAL c6dofimu2_init | ( | c6dofimu2_t * | ctx, |
c6dofimu2_cfg_t * | cfg ) |
Initialization function.
c6dofimu2 | Click object. |
cfg | Click configuration structure. |
@description This function initializes all necessary pins and peripherals used for this click.
void c6dofimu2_read_accel | ( | c6dofimu2_t * | ctx, |
c6dofimu2_accel_data_t * | accel_data ) |
Read axis function.
ctx | Click object. |
accel_data | Pointer to structure where Accel data be stored. |
@description This function read Accel X-axis, Y-axis and Z-axis.
void c6dofimu2_read_gyro | ( | c6dofimu2_t * | ctx, |
c6dofimu2_gyro_data_t * | gyro_data ) |
Read axis function.
ctx | Click object. |
gyro_data | Pointer to structure where Gyro data be stored. |
@description This function read Gyro X-axis, Y-axis and Z-axis.