LibDriver ADXL362
Loading...
Searching...
No Matches
adxl362 basic driver function

adxl362 basic driver modules More...

Collaboration diagram for adxl362 basic driver function:

Data Structures

struct  adxl362_frame_s
 adxl362 frame structure definition More...
struct  adxl362_handle_s
 adxl362 handle structure definition More...
struct  adxl362_info_s
 adxl362 information structure definition More...

Typedefs

typedef struct adxl362_frame_s adxl362_frame_t
 adxl362 frame structure definition
typedef struct adxl362_handle_s adxl362_handle_t
 adxl362 handle structure definition
typedef struct adxl362_info_s adxl362_info_t
 adxl362 information structure definition

Enumerations

enum  adxl362_bool_t { ADXL362_BOOL_FALSE = 0x00 , ADXL362_BOOL_TRUE = 0x01 }
 adxl362 bool enumeration definition More...
enum  adxl362_interrupt_pin_level_t { ADXL362_INTERRUPT_PIN_HIGH = 0x00 , ADXL362_INTERRUPT_PIN_LOW = 0x01 }
 adxl362 interrupt pin level enumeration definition More...
enum  adxl362_range_t { ADXL362_RANGE_2G = 0x00 , ADXL362_RANGE_4G = 0x01 , ADXL362_RANGE_8G = 0x02 }
 adxl362 range enumeration definition More...
enum  adxl362_bandwidth_t { ADXL362_BANDWIDTH_ODR_DIV_2 = 0x00 , ADXL362_BANDWIDTH_ODE_DIV_4 = 0x01 }
 adxl362 bandwidth enumeration definition More...
enum  adxl362_odr_t {
  ADXL362_ODR_12P5HZ = 0x00 , ADXL362_ODR_25HZ = 0x01 , ADXL362_ODR_50HZ = 0x02 , ADXL362_ODR_100HZ = 0x03 ,
  ADXL362_ODR_200HZ = 0x04 , ADXL362_ODR_400HZ = 0x05
}
 adxl362 odr enumeration definition More...
enum  adxl362_noise_mode_t { ADXL362_NOISE_MODE_NORMAL = 0x00 , ADXL362_NOISE_MODE_LOW_NOISE = 0x01 , ADXL362_NOISE_MODE_ULTRA_LOW_NOISE = 0x02 }
 adxl362 noise mode enumeration definition More...
enum  adxl362_mode_t { ADXL362_MODE_STANDBY = 0x00 , ADXL362_MODE_MEASUREMENT = 0x02 }
 adxl362 mode enumeration definition More...
enum  adxl362_detect_mode_t { ADXL362_DETECT_MODE_BOTH = 0x00 , ADXL362_DETECT_MODE_LINK = 0x01 , ADXL362_DETECT_MODE_LOOP = 0x03 }
 adxl362 detect mode enumeration definition More...
enum  adxl362_detect_trigger_t { ADXL362_DETECT_TRIGGER_ABSOLUTE = 0x00 , ADXL362_DETECT_TRIGGER_REFERENCED = 0x01 }
 adxl362 detect trigger enumeration definition More...
enum  adxl362_interrupt_map_t {
  ADXL362_INTERRUPT_MAP_AWAKE = 6 , ADXL362_INTERRUPT_MAP_INACT = 5 , ADXL362_INTERRUPT_MAP_ACT = 4 , ADXL362_INTERRUPT_MAP_FIFO_OVERRUN = 3 ,
  ADXL362_INTERRUPT_MAP_FIFO_WATERMARK = 2 , ADXL362_INTERRUPT_MAP_FIFO_READY = 1 , ADXL362_INTERRUPT_MAP_DATA_READY = 0
}
 adxl362 interrupt map enumeration definition More...
enum  adxl362_status_t {
  ADXL362_STATUS_ERR_USER_REGS = (1 << 7) , ADXL362_STATUS_AWAKE = (1 << 6) , ADXL362_STATUS_INACT = (1 << 5) , ADXL362_STATUS_ACT = (1 << 4) ,
  ADXL362_STATUS_FIFO_OVERRUN = (1 << 3) , ADXL362_STATUS_FIFO_WATERMARK = (1 << 2) , ADXL362_STATUS_FIFO_READY = (1 << 1) , ADXL362_STATUS_DATA_READY = (1 << 0)
}
 adxl362 status enumeration definition More...
enum  adxl362_fifo_mode_t { ADXL362_FIFO_MODE_DISABLE = 0x00 , ADXL362_FIFO_MODE_OLDEST_SAVED = 0x01 , ADXL362_FIFO_MODE_STREAM = 0x02 , ADXL362_FIFO_MODE_TRIGGERED = 0x03 }
 adxl362 fifo mode enumeration definition More...
enum  adxl362_frame_type_t { ADXL362_FRAME_TYPE_X = 0x00 , ADXL362_FRAME_TYPE_Y = 0x01 , ADXL362_FRAME_TYPE_Z = 0x02 , ADXL362_FRAME_TYPE_TEMP = 0x03 }
 adxl362 frame type enumeration definition More...

Functions

uint8_t adxl362_info (adxl362_info_t *info)
 get chip's information
uint8_t adxl362_irq_handler (adxl362_handle_t *handle)
 irq handler
uint8_t adxl362_init (adxl362_handle_t *handle)
 initialize the chip
uint8_t adxl362_deinit (adxl362_handle_t *handle)
 close the chip
uint8_t adxl362_read (adxl362_handle_t *handle, int16_t raw[3], float g[3])
 read the data
uint8_t adxl362_read_fifo (adxl362_handle_t *handle, adxl362_frame_t *frame, uint16_t *frame_len)
 read data from the fifo
uint8_t adxl362_read_8msb (adxl362_handle_t *handle, int8_t raw[3], float g[3])
 read the data with eight most significant bits
uint8_t adxl362_read_temperature (adxl362_handle_t *handle, int16_t *raw, float *temp)
 read the temperature
uint8_t adxl362_get_revision (adxl362_handle_t *handle, uint8_t *id)
 get the chip revision
uint8_t adxl362_get_status (adxl362_handle_t *handle, uint8_t *status)
 get the chip status
uint8_t adxl362_get_fifo_counter (adxl362_handle_t *handle, uint16_t *counter)
 get the fifo counter
uint8_t adxl362_soft_reset (adxl362_handle_t *handle)
 soft reset
uint8_t adxl362_set_fifo_temperature (adxl362_handle_t *handle, adxl362_bool_t enable)
 enable or disable saving temperature data to fifo
uint8_t adxl362_get_fifo_temperature (adxl362_handle_t *handle, adxl362_bool_t *enable)
 get the fifo temperature status
uint8_t adxl362_set_fifo_mode (adxl362_handle_t *handle, adxl362_fifo_mode_t mode)
 set the fifo mode
uint8_t adxl362_get_fifo_mode (adxl362_handle_t *handle, adxl362_fifo_mode_t *mode)
 get the fifo mode
uint8_t adxl362_set_fifo_sample (adxl362_handle_t *handle, uint16_t sample)
 set the fifo sample
uint8_t adxl362_get_fifo_sample (adxl362_handle_t *handle, uint16_t *sample)
 get the fifo sample
uint8_t adxl362_set_interrupt_pin1_active_level (adxl362_handle_t *handle, adxl362_interrupt_pin_level_t level)
 set the interrupt pin1 active level
uint8_t adxl362_get_interrupt_pin1_active_level (adxl362_handle_t *handle, adxl362_interrupt_pin_level_t *level)
 get the interrupt pin1 active level
uint8_t adxl362_set_interrupt_pin1_map (adxl362_handle_t *handle, adxl362_interrupt_map_t map, adxl362_bool_t enable)
 set the interrupt pin1 map
uint8_t adxl362_get_interrupt_pin1_map (adxl362_handle_t *handle, adxl362_interrupt_map_t map, adxl362_bool_t *enable)
 get the interrupt pin1 map
uint8_t adxl362_set_interrupt_pin2_active_level (adxl362_handle_t *handle, adxl362_interrupt_pin_level_t level)
 set the interrupt pin2 active level
uint8_t adxl362_get_interrupt_pin2_active_level (adxl362_handle_t *handle, adxl362_interrupt_pin_level_t *level)
 get the interrupt pin2 active level
uint8_t adxl362_set_interrupt_pin2_map (adxl362_handle_t *handle, adxl362_interrupt_map_t map, adxl362_bool_t enable)
 set the interrupt pin2 map
uint8_t adxl362_get_interrupt_pin2_map (adxl362_handle_t *handle, adxl362_interrupt_map_t map, adxl362_bool_t *enable)
 get the interrupt pin2 map
uint8_t adxl362_set_range (adxl362_handle_t *handle, adxl362_range_t range)
 set the measurement range
uint8_t adxl362_get_range (adxl362_handle_t *handle, adxl362_range_t *range)
 get the measurement range
uint8_t adxl362_set_bandwidth (adxl362_handle_t *handle, adxl362_bandwidth_t bandwidth)
 set the filter bandwidth
uint8_t adxl362_get_bandwidth (adxl362_handle_t *handle, adxl362_bandwidth_t *bandwidth)
 get the filter bandwidth
uint8_t adxl362_set_interrupt_pin2_as_external_sampling_trigger (adxl362_handle_t *handle, adxl362_bool_t enable)
 enable or disable interrupt pin2 as the external sampling trigger
uint8_t adxl362_get_interrupt_pin2_as_external_sampling_trigger (adxl362_handle_t *handle, adxl362_bool_t *enable)
 get the interrupt pin2 as the external sampling trigger status
uint8_t adxl362_set_odr (adxl362_handle_t *handle, adxl362_odr_t odr)
 set the output data rate
uint8_t adxl362_get_odr (adxl362_handle_t *handle, adxl362_odr_t *odr)
 get the output data rate
uint8_t adxl362_set_interrupt_pin1_as_external_clock (adxl362_handle_t *handle, adxl362_bool_t enable)
 enable or disable interrupt pin1 as the external clock
uint8_t adxl362_get_interrupt_pin1_as_external_clock (adxl362_handle_t *handle, adxl362_bool_t *enable)
 get the interrupt pin1 as the external clock status
uint8_t adxl362_set_noise_mode (adxl362_handle_t *handle, adxl362_noise_mode_t mode)
 set the noise mode
uint8_t adxl362_get_noise_mode (adxl362_handle_t *handle, adxl362_noise_mode_t *mode)
 get the noise mode
uint8_t adxl362_set_wake_up (adxl362_handle_t *handle, adxl362_bool_t enable)
 enable or disable chip wake up
uint8_t adxl362_get_wake_up (adxl362_handle_t *handle, adxl362_bool_t *enable)
 get the chip wake up status
uint8_t adxl362_set_auto_sleep (adxl362_handle_t *handle, adxl362_bool_t enable)
 enable or disable auto sleep
uint8_t adxl362_get_auto_sleep (adxl362_handle_t *handle, adxl362_bool_t *enable)
 get the auto sleep status
uint8_t adxl362_set_mode (adxl362_handle_t *handle, adxl362_mode_t mode)
 set the chip mode
uint8_t adxl362_get_mode (adxl362_handle_t *handle, adxl362_mode_t *mode)
 get the chip mode
uint8_t adxl362_set_activity_threshold (adxl362_handle_t *handle, uint16_t threshold)
 set the activity threshold
uint8_t adxl362_get_activity_threshold (adxl362_handle_t *handle, uint16_t *threshold)
 get the activity threshold
uint8_t adxl362_activity_threshold_convert_to_register (adxl362_handle_t *handle, float g, uint16_t *reg)
 convert the activity threshold to the register raw data
uint8_t adxl362_activity_threshold_convert_to_data (adxl362_handle_t *handle, uint16_t reg, float *g)
 convert the register raw data to the activity threshold
uint8_t adxl362_set_activity_time (adxl362_handle_t *handle, uint8_t tim)
 set the activity time
uint8_t adxl362_activity_time_convert_to_data (adxl362_handle_t *handle, uint8_t reg, float *ms)
 convert the register raw data to the activity time
uint8_t adxl362_activity_time_convert_to_register (adxl362_handle_t *handle, float ms, uint8_t *reg)
 convert the activity time to the register raw data
uint8_t adxl362_get_activity_time (adxl362_handle_t *handle, uint8_t *tim)
 get the activity time
uint8_t adxl362_set_inactivity_threshold (adxl362_handle_t *handle, uint16_t threshold)
 set the inactivity threshold
uint8_t adxl362_get_inactivity_threshold (adxl362_handle_t *handle, uint16_t *threshold)
 get the inactivity threshold
uint8_t adxl362_inactivity_threshold_convert_to_register (adxl362_handle_t *handle, float g, uint16_t *reg)
 convert the inactivity threshold to the register raw data
uint8_t adxl362_inactivity_threshold_convert_to_data (adxl362_handle_t *handle, uint16_t reg, float *g)
 convert the register raw data to the inactivity threshold
uint8_t adxl362_set_inactivity_time (adxl362_handle_t *handle, uint16_t tim)
 set the inactivity time
uint8_t adxl362_get_inactivity_time (adxl362_handle_t *handle, uint16_t *tim)
 get the inactivity time
uint8_t adxl362_inactivity_time_convert_to_register (adxl362_handle_t *handle, float ms, uint16_t *reg)
 convert the inactivity time to the register raw data
uint8_t adxl362_inactivity_time_convert_to_data (adxl362_handle_t *handle, uint16_t reg, float *ms)
 convert the register raw data to the inactivity time
uint8_t adxl362_set_detect_mode (adxl362_handle_t *handle, adxl362_detect_mode_t mode)
 set the detect mode
uint8_t adxl362_get_detect_mode (adxl362_handle_t *handle, adxl362_detect_mode_t *mode)
 get the detect mode
uint8_t adxl362_set_inactivity_detect_trigger (adxl362_handle_t *handle, adxl362_detect_trigger_t trigger)
 set the inactivity detect trigger mode
uint8_t adxl362_get_inactivity_detect_trigger (adxl362_handle_t *handle, adxl362_detect_trigger_t *trigger)
 get the inactivity detect trigger mode
uint8_t adxl362_set_activity_detect_trigger (adxl362_handle_t *handle, adxl362_detect_trigger_t trigger)
 set the activity detect trigger mode
uint8_t adxl362_get_activity_detect_trigger (adxl362_handle_t *handle, adxl362_detect_trigger_t *trigger)
 get the activity detect trigger mode
uint8_t adxl362_set_inactivity (adxl362_handle_t *handle, adxl362_bool_t enable)
 enable or disable inactivity
uint8_t adxl362_get_inactivity (adxl362_handle_t *handle, adxl362_bool_t *enable)
 get the inactivity status
uint8_t adxl362_set_activity (adxl362_handle_t *handle, adxl362_bool_t enable)
 enable or disable activity
uint8_t adxl362_get_activity (adxl362_handle_t *handle, adxl362_bool_t *enable)
 get the activity status
uint8_t adxl362_set_self_test (adxl362_handle_t *handle, adxl362_bool_t enable)
 enable or disable the self test
uint8_t adxl362_get_self_test (adxl362_handle_t *handle, adxl362_bool_t *enable)
 get the self test status

Detailed Description

adxl362 basic driver modules

Typedef Documentation

◆ adxl362_frame_t

adxl362 frame structure definition

◆ adxl362_handle_t

adxl362 handle structure definition

◆ adxl362_info_t

adxl362 information structure definition

Enumeration Type Documentation

◆ adxl362_bandwidth_t

adxl362 bandwidth enumeration definition

Enumerator
ADXL362_BANDWIDTH_ODR_DIV_2 

1/2 odr

ADXL362_BANDWIDTH_ODE_DIV_4 

1/4 odr

Definition at line 90 of file driver_adxl362.h.

◆ adxl362_bool_t

adxl362 bool enumeration definition

Enumerator
ADXL362_BOOL_FALSE 

false

ADXL362_BOOL_TRUE 

true

Definition at line 62 of file driver_adxl362.h.

◆ adxl362_detect_mode_t

adxl362 detect mode enumeration definition

Enumerator
ADXL362_DETECT_MODE_BOTH 

activity and inactivity detection both enabled mode

ADXL362_DETECT_MODE_LINK 

activity and inactivity detection link mode

ADXL362_DETECT_MODE_LOOP 

activity and inactivity detection loop mode

Definition at line 131 of file driver_adxl362.h.

◆ adxl362_detect_trigger_t

adxl362 detect trigger enumeration definition

Enumerator
ADXL362_DETECT_TRIGGER_ABSOLUTE 

operate in absolute mode

ADXL362_DETECT_TRIGGER_REFERENCED 

operate in referenced mode

Definition at line 141 of file driver_adxl362.h.

◆ adxl362_fifo_mode_t

adxl362 fifo mode enumeration definition

Enumerator
ADXL362_FIFO_MODE_DISABLE 

disabled

ADXL362_FIFO_MODE_OLDEST_SAVED 

oldest saved mode

ADXL362_FIFO_MODE_STREAM 

stream mode

ADXL362_FIFO_MODE_TRIGGERED 

triggered mode

Definition at line 179 of file driver_adxl362.h.

◆ adxl362_frame_type_t

adxl362 frame type enumeration definition

Enumerator
ADXL362_FRAME_TYPE_X 

x axis frame type

ADXL362_FRAME_TYPE_Y 

y axis frame type

ADXL362_FRAME_TYPE_Z 

z axis frame type

ADXL362_FRAME_TYPE_TEMP 

temperature frame type

Definition at line 190 of file driver_adxl362.h.

◆ adxl362_interrupt_map_t

adxl362 interrupt map enumeration definition

Enumerator
ADXL362_INTERRUPT_MAP_AWAKE 

awake status map

ADXL362_INTERRUPT_MAP_INACT 

inactivity status map

ADXL362_INTERRUPT_MAP_ACT 

activity status map

ADXL362_INTERRUPT_MAP_FIFO_OVERRUN 

fifo overrun status map

ADXL362_INTERRUPT_MAP_FIFO_WATERMARK 

fifo watermark status map

ADXL362_INTERRUPT_MAP_FIFO_READY 

fifo ready status map

ADXL362_INTERRUPT_MAP_DATA_READY 

data ready status map

Definition at line 150 of file driver_adxl362.h.

◆ adxl362_interrupt_pin_level_t

adxl362 interrupt pin level enumeration definition

Enumerator
ADXL362_INTERRUPT_PIN_HIGH 

active high

ADXL362_INTERRUPT_PIN_LOW 

active low

Definition at line 71 of file driver_adxl362.h.

◆ adxl362_mode_t

adxl362 mode enumeration definition

Enumerator
ADXL362_MODE_STANDBY 

standby mode

ADXL362_MODE_MEASUREMENT 

measurement mode

Definition at line 122 of file driver_adxl362.h.

◆ adxl362_noise_mode_t

adxl362 noise mode enumeration definition

Enumerator
ADXL362_NOISE_MODE_NORMAL 

normal operation mode

ADXL362_NOISE_MODE_LOW_NOISE 

low noise mode

ADXL362_NOISE_MODE_ULTRA_LOW_NOISE 

ultra low noise mode

Definition at line 112 of file driver_adxl362.h.

◆ adxl362_odr_t

adxl362 odr enumeration definition

Enumerator
ADXL362_ODR_12P5HZ 

12.5Hz

ADXL362_ODR_25HZ 

25Hz

ADXL362_ODR_50HZ 

50Hz

ADXL362_ODR_100HZ 

100Hz

ADXL362_ODR_200HZ 

200Hz

ADXL362_ODR_400HZ 

400Hz

Definition at line 99 of file driver_adxl362.h.

◆ adxl362_range_t

adxl362 range enumeration definition

Enumerator
ADXL362_RANGE_2G 

2g

ADXL362_RANGE_4G 

4g

ADXL362_RANGE_8G 

8g

Definition at line 80 of file driver_adxl362.h.

◆ adxl362_status_t

adxl362 status enumeration definition

Enumerator
ADXL362_STATUS_ERR_USER_REGS 

seu error detect

ADXL362_STATUS_AWAKE 

indicates whether the accelerometer is in an active or inactive

ADXL362_STATUS_INACT 

inactivity

ADXL362_STATUS_ACT 

activity

ADXL362_STATUS_FIFO_OVERRUN 

fifo overrun

ADXL362_STATUS_FIFO_WATERMARK 

fifo watermark

ADXL362_STATUS_FIFO_READY 

fifo ready

ADXL362_STATUS_DATA_READY 

data ready

Definition at line 164 of file driver_adxl362.h.

Function Documentation

◆ adxl362_activity_threshold_convert_to_data()

uint8_t adxl362_activity_threshold_convert_to_data ( adxl362_handle_t * handle,
uint16_t reg,
float * g )

convert the register raw data to the activity threshold

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]regregister raw data
[out]*gpointer to an activity threshold buffer
Returns
status code
  • 0 success
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2168 of file driver_adxl362.c.

◆ adxl362_activity_threshold_convert_to_register()

uint8_t adxl362_activity_threshold_convert_to_register ( adxl362_handle_t * handle,
float g,
uint16_t * reg )

convert the activity threshold to the register raw data

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]gactivity threshold
[out]*regpointer to a register raw buffer
Returns
status code
  • 0 success
  • 2 handle is NULL
  • 3 handle is not initialized
  • 4 g is invalid
Note
g >= 0.0f

Definition at line 2112 of file driver_adxl362.c.

◆ adxl362_activity_time_convert_to_data()

uint8_t adxl362_activity_time_convert_to_data ( adxl362_handle_t * handle,
uint8_t reg,
float * ms )

convert the register raw data to the activity time

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]regregister raw data
[out]*mspointer to an activity time buffer
Returns
status code
  • 0 success
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2361 of file driver_adxl362.c.

◆ adxl362_activity_time_convert_to_register()

uint8_t adxl362_activity_time_convert_to_register ( adxl362_handle_t * handle,
float ms,
uint8_t * reg )

convert the activity time to the register raw data

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]msactivity time in ms
[out]*regpointer to a register raw buffer
Returns
status code
  • 0 success
  • 2 handle is NULL
  • 3 handle is not initialized
  • 4 ms is invalid
Note
ms >= 0.0f

Definition at line 2293 of file driver_adxl362.c.

◆ adxl362_deinit()

uint8_t adxl362_deinit ( adxl362_handle_t * handle)

close the chip

Parameters
[in]*handlepointer to an adxl362 handle structure
Returns
status code
  • 0 success
  • 1 spi deinit failed
  • 2 handle is NULL
  • 3 handle is not initialized
  • 4 power down failed
Note
none

Definition at line 335 of file driver_adxl362.c.

◆ adxl362_get_activity()

uint8_t adxl362_get_activity ( adxl362_handle_t * handle,
adxl362_bool_t * enable )

get the activity status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get activity failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 3192 of file driver_adxl362.c.

◆ adxl362_get_activity_detect_trigger()

uint8_t adxl362_get_activity_detect_trigger ( adxl362_handle_t * handle,
adxl362_detect_trigger_t * trigger )

get the activity detect trigger mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*triggerpointer to a detect trigger mode buffer
Returns
status code
  • 0 success
  • 1 get activity detect trigger failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 3028 of file driver_adxl362.c.

◆ adxl362_get_activity_threshold()

uint8_t adxl362_get_activity_threshold ( adxl362_handle_t * handle,
uint16_t * threshold )

get the activity threshold

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*thresholdpointer to a threshold buffer
Returns
status code
  • 0 success
  • 1 get activity threshold failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2073 of file driver_adxl362.c.

◆ adxl362_get_activity_time()

uint8_t adxl362_get_activity_time ( adxl362_handle_t * handle,
uint8_t * tim )

get the activity time

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*timpointer to an activity time buffer
Returns
status code
  • 0 success
  • 1 get activity time failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2255 of file driver_adxl362.c.

◆ adxl362_get_auto_sleep()

uint8_t adxl362_get_auto_sleep ( adxl362_handle_t * handle,
adxl362_bool_t * enable )

get the auto sleep status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get auto sleep failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1827 of file driver_adxl362.c.

◆ adxl362_get_bandwidth()

uint8_t adxl362_get_bandwidth ( adxl362_handle_t * handle,
adxl362_bandwidth_t * bandwidth )

get the filter bandwidth

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*bandwidthpointer to a filter bandwidth buffer
Returns
status code
  • 0 success
  • 1 get bandwidth failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1335 of file driver_adxl362.c.

◆ adxl362_get_detect_mode()

uint8_t adxl362_get_detect_mode ( adxl362_handle_t * handle,
adxl362_detect_mode_t * mode )

get the detect mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*modepointer to a detect mode buffer
Returns
status code
  • 0 success
  • 1 get detect mode failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2864 of file driver_adxl362.c.

◆ adxl362_get_fifo_counter()

uint8_t adxl362_get_fifo_counter ( adxl362_handle_t * handle,
uint16_t * counter )

get the fifo counter

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*counterpointer to a counter buffer
Returns
status code
  • 0 success
  • 1 get fifo counter failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 531 of file driver_adxl362.c.

◆ adxl362_get_fifo_mode()

uint8_t adxl362_get_fifo_mode ( adxl362_handle_t * handle,
adxl362_fifo_mode_t * mode )

get the fifo mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*modepointer to a mode buffer
Returns
status code
  • 0 success
  • 1 get fifo mode failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 733 of file driver_adxl362.c.

◆ adxl362_get_fifo_sample()

uint8_t adxl362_get_fifo_sample ( adxl362_handle_t * handle,
uint16_t * sample )

get the fifo sample

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*samplepointer to a sample buffer
Returns
status code
  • 0 success
  • 1 get fifo sample failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 831 of file driver_adxl362.c.

◆ adxl362_get_fifo_temperature()

uint8_t adxl362_get_fifo_temperature ( adxl362_handle_t * handle,
adxl362_bool_t * enable )

get the fifo temperature status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get fifo temperature failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 651 of file driver_adxl362.c.

◆ adxl362_get_inactivity()

uint8_t adxl362_get_inactivity ( adxl362_handle_t * handle,
adxl362_bool_t * enable )

get the inactivity status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get inactivity failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 3110 of file driver_adxl362.c.

◆ adxl362_get_inactivity_detect_trigger()

uint8_t adxl362_get_inactivity_detect_trigger ( adxl362_handle_t * handle,
adxl362_detect_trigger_t * trigger )

get the inactivity detect trigger mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*triggerpointer to a detect trigger mode buffer
Returns
status code
  • 0 success
  • 1 get inactivity detect trigger failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2946 of file driver_adxl362.c.

◆ adxl362_get_inactivity_threshold()

uint8_t adxl362_get_inactivity_threshold ( adxl362_handle_t * handle,
uint16_t * threshold )

get the inactivity threshold

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*thresholdpointer to a threshold buffer
Returns
status code
  • 0 success
  • 1 get inactivity threshold failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2468 of file driver_adxl362.c.

◆ adxl362_get_inactivity_time()

uint8_t adxl362_get_inactivity_time ( adxl362_handle_t * handle,
uint16_t * tim )

get the inactivity time

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*timpointer to an inactivity time buffer
Returns
status code
  • 0 success
  • 1 get inactivity time failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2651 of file driver_adxl362.c.

◆ adxl362_get_interrupt_pin1_active_level()

uint8_t adxl362_get_interrupt_pin1_active_level ( adxl362_handle_t * handle,
adxl362_interrupt_pin_level_t * level )

get the interrupt pin1 active level

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*levelpointer to an interrupt pin active level buffer
Returns
status code
  • 0 success
  • 1 get interrupt pin active level failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 921 of file driver_adxl362.c.

◆ adxl362_get_interrupt_pin1_as_external_clock()

uint8_t adxl362_get_interrupt_pin1_as_external_clock ( adxl362_handle_t * handle,
adxl362_bool_t * enable )

get the interrupt pin1 as the external clock status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get interrupt pin1 as external clock failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1581 of file driver_adxl362.c.

◆ adxl362_get_interrupt_pin1_map()

uint8_t adxl362_get_interrupt_pin1_map ( adxl362_handle_t * handle,
adxl362_interrupt_map_t map,
adxl362_bool_t * enable )

get the interrupt pin1 map

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]mapinterrupt function map
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get interrupt pin map failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1005 of file driver_adxl362.c.

◆ adxl362_get_interrupt_pin2_active_level()

uint8_t adxl362_get_interrupt_pin2_active_level ( adxl362_handle_t * handle,
adxl362_interrupt_pin_level_t * level )

get the interrupt pin2 active level

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*levelpointer to an interrupt pin active level buffer
Returns
status code
  • 0 success
  • 1 get interrupt pin active level failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1087 of file driver_adxl362.c.

◆ adxl362_get_interrupt_pin2_as_external_sampling_trigger()

uint8_t adxl362_get_interrupt_pin2_as_external_sampling_trigger ( adxl362_handle_t * handle,
adxl362_bool_t * enable )

get the interrupt pin2 as the external sampling trigger status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get interrupt pin2 as external sampling trigger failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1417 of file driver_adxl362.c.

◆ adxl362_get_interrupt_pin2_map()

uint8_t adxl362_get_interrupt_pin2_map ( adxl362_handle_t * handle,
adxl362_interrupt_map_t map,
adxl362_bool_t * enable )

get the interrupt pin2 map

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]mapinterrupt function map
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get interrupt pin map failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1171 of file driver_adxl362.c.

◆ adxl362_get_mode()

uint8_t adxl362_get_mode ( adxl362_handle_t * handle,
adxl362_mode_t * mode )

get the chip mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*modepointer to a chip mode buffer
Returns
status code
  • 0 success
  • 1 get mode failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1909 of file driver_adxl362.c.

◆ adxl362_get_noise_mode()

uint8_t adxl362_get_noise_mode ( adxl362_handle_t * handle,
adxl362_noise_mode_t * mode )

get the noise mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*modepointer to a noise mode buffer
Returns
status code
  • 0 success
  • 1 get noise mode failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1663 of file driver_adxl362.c.

◆ adxl362_get_odr()

uint8_t adxl362_get_odr ( adxl362_handle_t * handle,
adxl362_odr_t * odr )

get the output data rate

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*odrpointer to an output data rate buffer
Returns
status code
  • 0 success
  • 1 get odr failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1499 of file driver_adxl362.c.

◆ adxl362_get_range()

uint8_t adxl362_get_range ( adxl362_handle_t * handle,
adxl362_range_t * range )

get the measurement range

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*rangepointer to a measurement range buffer
Returns
status code
  • 0 success
  • 1 get range failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1253 of file driver_adxl362.c.

◆ adxl362_get_revision()

uint8_t adxl362_get_revision ( adxl362_handle_t * handle,
uint8_t * id )

get the chip revision

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*idpointer to an id buffer
Returns
status code
  • 0 success
  • 1 get revision failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 168 of file driver_adxl362.c.

◆ adxl362_get_self_test()

uint8_t adxl362_get_self_test ( adxl362_handle_t * handle,
adxl362_bool_t * enable )

get the self test status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get self test failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1991 of file driver_adxl362.c.

◆ adxl362_get_status()

uint8_t adxl362_get_status ( adxl362_handle_t * handle,
uint8_t * status )

get the chip status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*statuspointer to a status buffer
Returns
status code
  • 0 success
  • 1 get status failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 496 of file driver_adxl362.c.

◆ adxl362_get_wake_up()

uint8_t adxl362_get_wake_up ( adxl362_handle_t * handle,
adxl362_bool_t * enable )

get the chip wake up status

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*enablepointer to a bool value buffer
Returns
status code
  • 0 success
  • 1 get wake up failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1745 of file driver_adxl362.c.

◆ adxl362_inactivity_threshold_convert_to_data()

uint8_t adxl362_inactivity_threshold_convert_to_data ( adxl362_handle_t * handle,
uint16_t reg,
float * g )

convert the register raw data to the inactivity threshold

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]regregister raw data
[out]*gpointer to an inactivity threshold buffer
Returns
status code
  • 0 success
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2563 of file driver_adxl362.c.

◆ adxl362_inactivity_threshold_convert_to_register()

uint8_t adxl362_inactivity_threshold_convert_to_register ( adxl362_handle_t * handle,
float g,
uint16_t * reg )

convert the inactivity threshold to the register raw data

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]ginactivity threshold
[out]*regpointer to a register raw buffer
Returns
status code
  • 0 success
  • 2 handle is NULL
  • 3 handle is not initialized
  • 4 g is invalid
Note
g >= 0.0f

Definition at line 2507 of file driver_adxl362.c.

◆ adxl362_inactivity_time_convert_to_data()

uint8_t adxl362_inactivity_time_convert_to_data ( adxl362_handle_t * handle,
uint16_t reg,
float * ms )

convert the register raw data to the inactivity time

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]regregister raw data
[out]*mspointer to an inactivity time buffer
Returns
status code
  • 0 success
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2757 of file driver_adxl362.c.

◆ adxl362_inactivity_time_convert_to_register()

uint8_t adxl362_inactivity_time_convert_to_register ( adxl362_handle_t * handle,
float ms,
uint16_t * reg )

convert the inactivity time to the register raw data

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]msinactivity time in ms
[out]*regpointer to a register raw buffer
Returns
status code
  • 0 success
  • 2 handle is NULL
  • 3 handle is not initialized
  • 4 ms is invalid
Note
ms >= 0.0f

Definition at line 2689 of file driver_adxl362.c.

◆ adxl362_info()

uint8_t adxl362_info ( adxl362_info_t * info)

get chip's information

Parameters
[out]*infopointer to an adxl362 info structure
Returns
status code
  • 0 success
  • 2 handle is NULL
Note
none

Definition at line 3583 of file driver_adxl362.c.

◆ adxl362_init()

uint8_t adxl362_init ( adxl362_handle_t * handle)

initialize the chip

Parameters
[in]*handlepointer to an adxl362 handle structure
Returns
status code
  • 0 success
  • 1 spi initialization failed
  • 2 handle is NULL
  • 3 linked functions is NULL
  • 4 id is invalid
  • 5 soft reset failed
Note
none

Definition at line 204 of file driver_adxl362.c.

◆ adxl362_irq_handler()

uint8_t adxl362_irq_handler ( adxl362_handle_t * handle)

irq handler

Parameters
[in]*handlepointer to an adxl362 handle structure
Returns
status code
  • 0 success
  • 1 run failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 3413 of file driver_adxl362.c.

◆ adxl362_read()

uint8_t adxl362_read ( adxl362_handle_t * handle,
int16_t raw[3],
float g[3] )

read the data

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*rawpointer to a raw data buffer
[out]*gpointer to a converted data buffer
Returns
status code
  • 0 success
  • 1 read failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 3230 of file driver_adxl362.c.

◆ adxl362_read_8msb()

uint8_t adxl362_read_8msb ( adxl362_handle_t * handle,
int8_t raw[3],
float g[3] )

read the data with eight most significant bits

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*rawpointer to a raw data buffer
[out]*gpointer to a converted data buffer
Returns
status code
  • 0 success
  • 1 read 8msb failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 390 of file driver_adxl362.c.

◆ adxl362_read_fifo()

uint8_t adxl362_read_fifo ( adxl362_handle_t * handle,
adxl362_frame_t * frame,
uint16_t * frame_len )

read data from the fifo

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*framepointer to a frame buffer
[in,out]*frame_lenpointer to a frame length buffer
Returns
status code
  • 0 success
  • 1 read fifo failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 3304 of file driver_adxl362.c.

◆ adxl362_read_temperature()

uint8_t adxl362_read_temperature ( adxl362_handle_t * handle,
int16_t * raw,
float * temp )

read the temperature

Parameters
[in]*handlepointer to an adxl362 handle structure
[out]*rawpointer to a raw data buffer
[out]*temppointer to a converted temperature data buffer
Returns
status code
  • 0 success
  • 1 read temperature failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 458 of file driver_adxl362.c.

◆ adxl362_set_activity()

uint8_t adxl362_set_activity ( adxl362_handle_t * handle,
adxl362_bool_t enable )

enable or disable activity

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set activity failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 3147 of file driver_adxl362.c.

◆ adxl362_set_activity_detect_trigger()

uint8_t adxl362_set_activity_detect_trigger ( adxl362_handle_t * handle,
adxl362_detect_trigger_t trigger )

set the activity detect trigger mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]triggerdetect trigger mode
Returns
status code
  • 0 success
  • 1 set activity detect trigger failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2983 of file driver_adxl362.c.

◆ adxl362_set_activity_threshold()

uint8_t adxl362_set_activity_threshold ( adxl362_handle_t * handle,
uint16_t threshold )

set the activity threshold

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]thresholdactivity threshold
Returns
status code
  • 0 success
  • 1 set activity threshold failed
  • 2 handle is NULL
  • 3 handle is not initialized
  • 4 threshold is invalid
Note
0 <= threshold <= 0x07FF

Definition at line 2029 of file driver_adxl362.c.

◆ adxl362_set_activity_time()

uint8_t adxl362_set_activity_time ( adxl362_handle_t * handle,
uint8_t tim )

set the activity time

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]timactivity time
Returns
status code
  • 0 success
  • 1 set activity time failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2218 of file driver_adxl362.c.

◆ adxl362_set_auto_sleep()

uint8_t adxl362_set_auto_sleep ( adxl362_handle_t * handle,
adxl362_bool_t enable )

enable or disable auto sleep

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set auto sleep failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1782 of file driver_adxl362.c.

◆ adxl362_set_bandwidth()

uint8_t adxl362_set_bandwidth ( adxl362_handle_t * handle,
adxl362_bandwidth_t bandwidth )

set the filter bandwidth

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]bandwidthfilter bandwidth
Returns
status code
  • 0 success
  • 1 set bandwidth failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1290 of file driver_adxl362.c.

◆ adxl362_set_detect_mode()

uint8_t adxl362_set_detect_mode ( adxl362_handle_t * handle,
adxl362_detect_mode_t mode )

set the detect mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]modedetect mode
Returns
status code
  • 0 success
  • 1 set detect mode failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2819 of file driver_adxl362.c.

◆ adxl362_set_fifo_mode()

uint8_t adxl362_set_fifo_mode ( adxl362_handle_t * handle,
adxl362_fifo_mode_t mode )

set the fifo mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]modefifo mode
Returns
status code
  • 0 success
  • 1 set fifo mode failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 688 of file driver_adxl362.c.

◆ adxl362_set_fifo_sample()

uint8_t adxl362_set_fifo_sample ( adxl362_handle_t * handle,
uint16_t sample )

set the fifo sample

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]samplenumber of samples to store in the fifo
Returns
status code
  • 0 success
  • 1 set fifo sample failed
  • 2 handle is NULL
  • 3 handle is not initialized
  • 4 sample > 511
Note
0 <= sample <= 511

Definition at line 771 of file driver_adxl362.c.

◆ adxl362_set_fifo_temperature()

uint8_t adxl362_set_fifo_temperature ( adxl362_handle_t * handle,
adxl362_bool_t enable )

enable or disable saving temperature data to fifo

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set fifo temperature failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 606 of file driver_adxl362.c.

◆ adxl362_set_inactivity()

uint8_t adxl362_set_inactivity ( adxl362_handle_t * handle,
adxl362_bool_t enable )

enable or disable inactivity

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set inactivity failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 3065 of file driver_adxl362.c.

◆ adxl362_set_inactivity_detect_trigger()

uint8_t adxl362_set_inactivity_detect_trigger ( adxl362_handle_t * handle,
adxl362_detect_trigger_t trigger )

set the inactivity detect trigger mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]triggerdetect trigger mode
Returns
status code
  • 0 success
  • 1 set inactivity detect trigger failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2901 of file driver_adxl362.c.

◆ adxl362_set_inactivity_threshold()

uint8_t adxl362_set_inactivity_threshold ( adxl362_handle_t * handle,
uint16_t threshold )

set the inactivity threshold

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]thresholdinactivity threshold
Returns
status code
  • 0 success
  • 1 set inactivity threshold failed
  • 2 handle is NULL
  • 3 handle is not initialized
  • 4 threshold is invalid
Note
0 <= threshold <= 0x07FF

Definition at line 2424 of file driver_adxl362.c.

◆ adxl362_set_inactivity_time()

uint8_t adxl362_set_inactivity_time ( adxl362_handle_t * handle,
uint16_t tim )

set the inactivity time

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]timinactivity time
Returns
status code
  • 0 success
  • 1 set inactivity time failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 2613 of file driver_adxl362.c.

◆ adxl362_set_interrupt_pin1_active_level()

uint8_t adxl362_set_interrupt_pin1_active_level ( adxl362_handle_t * handle,
adxl362_interrupt_pin_level_t level )

set the interrupt pin1 active level

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]levelinterrupt pin active level
Returns
status code
  • 0 success
  • 1 set interrupt pin active level failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 876 of file driver_adxl362.c.

◆ adxl362_set_interrupt_pin1_as_external_clock()

uint8_t adxl362_set_interrupt_pin1_as_external_clock ( adxl362_handle_t * handle,
adxl362_bool_t enable )

enable or disable interrupt pin1 as the external clock

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set interrupt pin1 as external clock failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1536 of file driver_adxl362.c.

◆ adxl362_set_interrupt_pin1_map()

uint8_t adxl362_set_interrupt_pin1_map ( adxl362_handle_t * handle,
adxl362_interrupt_map_t map,
adxl362_bool_t enable )

set the interrupt pin1 map

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]mapinterrupt function map
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set interrupt pin map failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 959 of file driver_adxl362.c.

◆ adxl362_set_interrupt_pin2_active_level()

uint8_t adxl362_set_interrupt_pin2_active_level ( adxl362_handle_t * handle,
adxl362_interrupt_pin_level_t level )

set the interrupt pin2 active level

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]levelinterrupt pin active level
Returns
status code
  • 0 success
  • 1 set interrupt pin active level failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1042 of file driver_adxl362.c.

◆ adxl362_set_interrupt_pin2_as_external_sampling_trigger()

uint8_t adxl362_set_interrupt_pin2_as_external_sampling_trigger ( adxl362_handle_t * handle,
adxl362_bool_t enable )

enable or disable interrupt pin2 as the external sampling trigger

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set interrupt pin2 as external sampling trigger failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1372 of file driver_adxl362.c.

◆ adxl362_set_interrupt_pin2_map()

uint8_t adxl362_set_interrupt_pin2_map ( adxl362_handle_t * handle,
adxl362_interrupt_map_t map,
adxl362_bool_t enable )

set the interrupt pin2 map

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]mapinterrupt function map
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set interrupt pin map failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1125 of file driver_adxl362.c.

◆ adxl362_set_mode()

uint8_t adxl362_set_mode ( adxl362_handle_t * handle,
adxl362_mode_t mode )

set the chip mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]modechip mode
Returns
status code
  • 0 success
  • 1 set mode failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1864 of file driver_adxl362.c.

◆ adxl362_set_noise_mode()

uint8_t adxl362_set_noise_mode ( adxl362_handle_t * handle,
adxl362_noise_mode_t mode )

set the noise mode

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]modenoise mode
Returns
status code
  • 0 success
  • 1 set noise mode failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1618 of file driver_adxl362.c.

◆ adxl362_set_odr()

uint8_t adxl362_set_odr ( adxl362_handle_t * handle,
adxl362_odr_t odr )

set the output data rate

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]odroutput data rate
Returns
status code
  • 0 success
  • 1 set odr failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1454 of file driver_adxl362.c.

◆ adxl362_set_range()

uint8_t adxl362_set_range ( adxl362_handle_t * handle,
adxl362_range_t range )

set the measurement range

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]rangemeasurement range
Returns
status code
  • 0 success
  • 1 set range failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1208 of file driver_adxl362.c.

◆ adxl362_set_self_test()

uint8_t adxl362_set_self_test ( adxl362_handle_t * handle,
adxl362_bool_t enable )

enable or disable the self test

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set self test failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1946 of file driver_adxl362.c.

◆ adxl362_set_wake_up()

uint8_t adxl362_set_wake_up ( adxl362_handle_t * handle,
adxl362_bool_t enable )

enable or disable chip wake up

Parameters
[in]*handlepointer to an adxl362 handle structure
[in]enablebool value
Returns
status code
  • 0 success
  • 1 set wake up failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1700 of file driver_adxl362.c.

◆ adxl362_soft_reset()

uint8_t adxl362_soft_reset ( adxl362_handle_t * handle)

soft reset

Parameters
[in]*handlepointer to an adxl362 handle structure
Returns
status code
  • 0 success
  • 1 soft reset failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 568 of file driver_adxl362.c.