accel11 2.0.0.0
Public function

Functions

void accel11_cfg_setup (accel11_cfg_t *cfg)
 Config Object Initialization function.
 
ACCEL11_RETVAL accel11_init (accel11_t *ctx, accel11_cfg_t *cfg)
 Initialization function.
 
void accel11_default_cfg (accel11_t *ctx)
 Click Default Configuration function.
 
void accel11_generic_write (accel11_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
 Generic write function.
 
void accel11_generic_read (accel11_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
 Generic read function.
 
void accel11_write_byte (accel11_t *ctx, uint8_t addr, uint8_t data_in)
 Functions for write one byte in register.
 
uint8_t accel11_read_byte (accel11_t *ctx, uint8_t addr)
 Functions for read byte from register.
 
uint8_t accel11_test_comunication (accel11_t *ctx)
 Test comunication function.
 
void accel11_software_reset (accel11_t *ctx)
 Software reset function.
 
int16_t accel11_get_axis_data (accel11_t *ctx, uint8_t axis)
 Accel Axis data function.
 
void accel11_power_on_procedure (accel11_t *ctx)
 Function for power on chip.
 
int8_t accel11_get_temperature (accel11_t *ctx)
 Function get temperature.
 

Detailed Description

Function Documentation

◆ accel11_cfg_setup()

void accel11_cfg_setup ( accel11_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.

◆ accel11_default_cfg()

void accel11_default_cfg ( accel11_t * ctx)

Click Default Configuration function.

Parameters
ctxClick object.

@description This function executes default configuration for Accel 11 click.

◆ accel11_generic_read()

void accel11_generic_read ( accel11_t * ctx,
uint8_t reg,
uint8_t * data_buf,
uint8_t len )

Generic read function.

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

@description This function reads data from the desired register.

◆ accel11_generic_write()

void accel11_generic_write ( accel11_t * ctx,
uint8_t reg,
uint8_t * data_buf,
uint8_t len )

Generic write function.

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

@description This function writes data to the desired register.

◆ accel11_get_axis_data()

int16_t accel11_get_axis_data ( accel11_t * ctx,
uint8_t axis )

Accel Axis data function.

Parameters
ctxClick object.
axisAccel axis that will be read.

@description This function reads accel axis.

◆ accel11_get_temperature()

int8_t accel11_get_temperature ( accel11_t * ctx)

Function get temperature.

Parameters
ctxClick object.

@description This function gets temperature in celsius [C].

◆ accel11_init()

ACCEL11_RETVAL accel11_init ( accel11_t * ctx,
accel11_cfg_t * cfg )

Initialization function.

Parameters
accel11Click object.
cfgClick configuration structure.

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

◆ accel11_power_on_procedure()

void accel11_power_on_procedure ( accel11_t * ctx)

Function for power on chip.

Parameters
ctxClick object.

@description This function for power on chip.

◆ accel11_read_byte()

uint8_t accel11_read_byte ( accel11_t * ctx,
uint8_t addr )

Functions for read byte from register.

Parameters
ctxClick object.
addrRegister which will be read.

@description This function reads byte from register.

◆ accel11_software_reset()

void accel11_software_reset ( accel11_t * ctx)

Software reset function.

Parameters
ctxClick object.

@description This function reset software.

◆ accel11_test_comunication()

uint8_t accel11_test_comunication ( accel11_t * ctx)

Test comunication function.

Parameters
ctxClick object.

@description This function test comunication.

◆ accel11_write_byte()

void accel11_write_byte ( accel11_t * ctx,
uint8_t addr,
uint8_t data_in )

Functions for write one byte in register.

Parameters
ctxClick object.
addrRegister in which the data will be written.
data_inData which be written in the register.

@description This function writes one byte in register.