c6dofimu10 2.0.0.0

Functions

void c6dofimu10_cfg_setup (c6dofimu10_cfg_t *cfg)
 Config Object Initialization function.
 
c6DOFIMU10_RETVAL c6dofimu10_init (c6dofimu10_t *ctx, c6dofimu10_cfg_t *cfg)
 Initialization function.
 
void c6dofimu10_default_cfg (c6dofimu10_t *ctx)
 Click Default Configuration function.
 
void c6dofimu10_generic_write (c6dofimu10_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
 Generic write function.
 
void c6dofimu10_generic_read (c6dofimu10_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
 Generic read function.
 
void c6dofimu10_measurement_cfg (c6dofimu10_t *ctx, c6dofimu10_cfg_t *cfg)
 Measurement config.
 
void c6dofimu10_get_accel_axis (c6dofimu10_t *ctx, c6dofimu10_axis_t *axis)
 Accelerometer axis data.
 
void c6dofimu10_get_mag_axis (c6dofimu10_t *ctx, c6dofimu10_axis_t *axis)
 Magnetometer axis data.
 
float c6dofimu10_get_temperature (c6dofimu10_t *ctx, uint8_t temp_format)
 Temperature data.
 
uint8_t c6dofimu10_communication_test (c6dofimu10_t *ctx)
 Communication test.
 
void c6dofimu10_get_motion (c6dofimu10_t *ctx, uint8_t sensor_reg, c6dofimu10_motion_t *motion_obj)
 Get motion interrupt status.
 
uint8_t c6dofimu10_get_interrupt (c6dofimu10_t *ctx, uint8_t int_pin)
 Get interrupt pin status.
 

Detailed Description

Function Documentation

◆ c6dofimu10_cfg_setup()

void c6dofimu10_cfg_setup ( c6dofimu10_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.

◆ c6dofimu10_communication_test()

uint8_t c6dofimu10_communication_test ( c6dofimu10_t * ctx)

Communication test.

Parameters
ctxClick object.

@description This function test communication.

Note
Test comunication info:
   - C6DOFIMU10_DEVICE_OK   
   - C6DOFIMU10_DEVICE_ERROR

◆ c6dofimu10_default_cfg()

void c6dofimu10_default_cfg ( c6dofimu10_t * ctx)

Click Default Configuration function.

Parameters
ctxClick object.

@description This function executes default configuration for c6DofImu10 click.

◆ c6dofimu10_generic_read()

void c6dofimu10_generic_read ( c6dofimu10_t * ctx,
uint8_t reg,
uint8_t * data_buf,
uint8_t len )

Generic read function.

Parameters
ctxClick object.
regRegister address.
data_bufOutput data buf.
lenNumber of the bytes to be read.

@description This function reads data from the desired register.

◆ c6dofimu10_generic_write()

void c6dofimu10_generic_write ( c6dofimu10_t * ctx,
uint8_t reg,
uint8_t * data_buf,
uint8_t len )

Generic write function.

Parameters
ctxClick object.
regRegister address.
data_bufData buf to be written.
lenNumber of the bytes in data buf.

@description This function writes data to the desired register.

◆ c6dofimu10_get_accel_axis()

void c6dofimu10_get_accel_axis ( c6dofimu10_t * ctx,
c6dofimu10_axis_t * axis )

Accelerometer axis data.

Parameters
ctxClick object.
axisMeasurement config structure.

@description This function gets accelerometer axis data.

Note
axis data contains
    - X axis data
    - Y axis data
    - Z axis data

◆ c6dofimu10_get_interrupt()

uint8_t c6dofimu10_get_interrupt ( c6dofimu10_t * ctx,
uint8_t int_pin )

Get interrupt pin status.

Parameters
ctxClick object.
int_pinSensor register.

@description This function gets interrupt.

Note
Interrupt pin options:
  - C6DOFIMU10_GP1_INT_PIN - PWM pin 
  - C6DOFIMU10_GP2_INT_PIN - RST pin 

◆ c6dofimu10_get_mag_axis()

void c6dofimu10_get_mag_axis ( c6dofimu10_t * ctx,
c6dofimu10_axis_t * axis )

Magnetometer axis data.

Parameters
ctxClick object.
axisMeasurement config structure.

@description This function gets magnetometer axis data.

Note
axis data contains
    - X axis data
    - Y axis data
    - Z axis data

◆ c6dofimu10_get_motion()

void c6dofimu10_get_motion ( c6dofimu10_t * ctx,
uint8_t sensor_reg,
c6dofimu10_motion_t * motion_obj )

Get motion interrupt status.

Parameters
ctxClick object.
sensor_regSensor register.
motion_objMotion status object.

@description This function gets motion.

Note
Sensor register options:
   - INS3 - Interrupt Source Register 3   
   - INS2 - Interrupt Source Register 2

◆ c6dofimu10_get_temperature()

float c6dofimu10_get_temperature ( c6dofimu10_t * ctx,
uint8_t temp_format )

Temperature data.

Parameters
ctxClick object.
temp_formatTemperature data format.

@description This function gets temperature data.

Note
Temperature format options:
   - C6DOFIMU10_TEMP_FORMAT_FARENHAJT 
   - C6DOFIMU10_TEMP_FORMAT_KELVIN    
   - C6DOFIMU10_TEMP_FORMAT_CELSIUS 

◆ c6dofimu10_init()

c6DOFIMU10_RETVAL c6dofimu10_init ( c6dofimu10_t * ctx,
c6dofimu10_cfg_t * cfg )

Initialization function.

Parameters
c6dofimu10Click object.
cfgClick configuration structure.

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

◆ c6dofimu10_measurement_cfg()

void c6dofimu10_measurement_cfg ( c6dofimu10_t * ctx,
c6dofimu10_cfg_t * cfg )

Measurement config.

Parameters
ctxClick object.
cfgMeasurement config structure.

@description This function sets measurement config.