Go to the documentation of this file.
34 #ifndef IIO_ADIS1646X_H
35 #define IIO_ADIS1646X_H
int adis_write_dr_polarity(struct adis_dev *adis, uint32_t dr_polarity)
Write data ready polarity encoded value.
Definition: adis.c:2601
@ IIO_ACCEL
Definition: iio_types.h:71
int adis_write_gpio_lvl(struct adis_dev *adis, uint8_t dio_nb, uint32_t level)
Write gpio level configuration.
Definition: adis.c:3003
int adis_write_zg_scale(struct adis_dev *adis, int32_t zg_scale)
Write raw gyroscope scale adjustment on z axis.
Definition: adis.c:1755
int adis_write_fifo_en(struct adis_dev *adis, uint32_t fifo_en)
Write FIFO enable bit value.
Definition: adis.c:1847
@ ADIS16475_3
Definition: adis.h:84
@ ADIS_CMD_SNSR_SELF_TEST
Definition: iio_adis_internals.h:173
int adis_read_prod_id(struct adis_dev *adis, uint32_t *prod_id)
Read product id value.
Definition: adis.c:3791
@ ADIS_DELTA_ANGL_Z
Definition: iio_adis_internals.h:62
int adis_read_fir_en_xa(struct adis_dev *adis, uint32_t *fir_en_xa)
Read x axis accelerometer filter enable bit value.
Definition: adis.c:2141
@ ADIS_DIO_3_DIR
Definition: iio_adis_internals.h:132
int adis_iio_read_offset(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the read request for offset attribute.
Definition: iio_adis.c:246
int adis_write_up_scale(struct adis_dev *adis, uint32_t up_scale)
Write external clock scale factor value.
Definition: adis.c:3338
@ ADIS16465_1
Definition: adis.h:75
int adis_iio_pre_enable(void *dev, uint32_t mask)
API to be called before trigger is enabled.
Definition: iio_adis.c:1412
int adis_iio_write_lpf(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the write request for lpf attribute.
Definition: iio_adis.c:562
@ ADIS_FIR_BANK_SEL_ZG
Definition: iio_adis_internals.h:155
int adis_cmd_snsr_self_test(struct adis_dev *adis)
Command: sensor self test.
Definition: adis.c:3613
int adis_read_lot_num(struct adis_dev *adis, uint32_t *lot_num)
Read lot specific number value.
Definition: adis.c:3813
#define END_ATTRIBUTES_ARRAY
Definition: iio_types.h:116
struct iio_attribute adis_dev_attrs[]
Definition: iio_adis.c:1803
uint32_t burst_sel
Definition: iio_adis_internals.h:232
struct iio_attribute adis_iio_delta_vel_attrs[]
Definition: iio_adis.c:1880
@ ADIS_DIAG_FLS_MEM_WR_CNT_EXCEED
Definition: iio_adis_internals.h:103
uint32_t samples
Definition: iio_types.h:217
@ ADIS16470
Definition: adis.h:81
int adis_iio_write_sampling_freq(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the write request for sampling frequency attribute.
Definition: iio_adis.c:753
Header file for iio_trigger.
@ ADIS_FIR_EN_XG
Definition: iio_adis_internals.h:147
int adis_read_diag_config_calib_crc_error(struct adis_dev *adis, uint32_t *config_calib_crc_error)
Diagnosis: read configuration and/or calibration CRC error flag value.
Definition: adis.c:1022
int adis_read_fir_en_za(struct adis_dev *adis, uint32_t *fir_en_za)
Read z axis accelerometer filter enable bit value.
Definition: adis.c:2189
int adis_write_fir_en_xa(struct adis_dev *adis, uint32_t fir_en_xa)
Write x axis accelerometer filter enable bit value.
Definition: adis.c:2153
int adis_read_firm_m(struct adis_dev *adis, uint32_t *firm_m)
Read firmware factory configuration month value.
Definition: adis.c:3758
int adis_get_deltaangl_scale(struct adis_dev *adis, struct adis_scale_fractional_log2 *deltaangl_scale)
Read adis device delta angle scale in fractional form.
Definition: adis.c:4177
int adis_read_y_deltang(struct adis_dev *adis, int32_t *y_deltang)
Read raw delta angle data on y axis.
Definition: adis.c:1449
@ ADIS_GYRO_CHAN
Definition: adis.h:116
int adis_read_diag_snsr_failure(struct adis_dev *adis, uint32_t *snsr_failure)
Diagnosis: read sensor self test error flag value.
Definition: adis.c:755
@ IIO_ANGL_VEL
Definition: iio_types.h:68
uint16_t samples_lost
Definition: iio_adis_internals.h:224
@ IIO_VAL_INT
Definition: iio_types.h:50
Struct describing the scan type.
Definition: iio_types.h:168
@ ADIS_DIAG_EXT_5V_SUPPLY_ERR
Definition: iio_adis_internals.h:99
@ ADIS_FIFO_WM_INT_EN
Definition: iio_adis_internals.h:114
@ ADIS_ACCEL_Z
Definition: iio_adis_internals.h:58
char sign
Definition: iio_types.h:153
@ ADIS_DIAG_POWER_SUPPLY_FAILURE
Definition: iio_adis_internals.h:94
@ ADIS_DIAG_FLS_MEM_UPDATE_FAILURE
Definition: iio_adis_internals.h:75
int adis_read_fifo_wm_int_pol(struct adis_dev *adis, uint32_t *fifo_wm_int_pol)
Read FIFO watermark interrupt polarity bit value.
Definition: adis.c:1914
#define ADIS_HAS_BURST_DELTA_DATA
Definition: adis_internals.h:39
int adis_write_timestamp32(struct adis_dev *adis, uint32_t timestamp32)
Write timestamp32 enable bit value.
Definition: adis.c:3275
int adis_write_accl_fir_enable(struct adis_dev *adis, uint32_t accl_fir_enable)
Write accelerometer FIR filter control bit value.
Definition: adis.c:3075
int adis_read_z_deltvel(struct adis_dev *adis, int32_t *z_deltvel)
Read raw delta velocity data on z axis.
Definition: adis.c:1525
Internal include file used for specific chip driver definitions, which are not useful for the user.
int adis_read_fir_bank_sel_za(struct adis_dev *adis, uint32_t *fir_bank_sel_za)
Read z axis accelerometer filter bank selection encoded value.
Definition: adis.c:2377
int adis_read_diag_aduc_mcu_fault(struct adis_dev *adis, uint32_t *aduc_mcu_fault)
Diagnosis: read ADuC microcontroller fault flag value.
Definition: adis.c:1001
int adis_read_diag_power_supply_failure(struct adis_dev *adis, uint32_t *power_supply_failure)
Diagnosis: read power supply error flag value.
Definition: adis.c:1085
@ ADIS_DR_ENABLE
Definition: iio_adis_internals.h:121
@ ADIS_GYRO_Z
Definition: iio_adis_internals.h:55
@ IIO_SHARED_BY_TYPE
Definition: iio_types.h:120
@ ADIS_ALARM_IND_ENABLE
Definition: iio_adis_internals.h:127
@ ADIS_BOOT_REV
Definition: iio_adis_internals.h:181
#define NO_OS_GENMASK(h, l)
Definition: no_os_util.h:82
void adis_read_diag_checksum_err(struct adis_dev *adis, uint32_t *checksum_err)
Diagnosis: read checksum error flag value.
Definition: adis.c:1252
int adis_read_diag_x_axis_accl_failure(struct adis_dev *adis, uint32_t *x_axis_accl_failure)
Diagnosis: read X-Axis Accelerometer failure flag value.
Definition: adis.c:938
struct iio_channel * channels
Definition: iio_types.h:254
uint32_t sync_mode
Definition: iio_adis_internals.h:234
@ ADIS16467_3
Definition: adis.h:80
int adis_update_ext_clk_freq(struct adis_dev *adis, uint32_t clk_freq)
Update external clock frequency.
Definition: adis.c:4095
struct iio_hw_trig * hw_trig_desc
Definition: iio_adis_internals.h:241
int adis_read_boot_rev(struct adis_dev *adis, uint32_t *boot_rev)
Read boot loader revision value.
Definition: adis.c:3780
struct iio_device * iio_dev
Definition: iio_adis_internals.h:222
@ IIO_VAL_FRACTIONAL_LOG2
Definition: iio_types.h:56
void * dev
Definition: iio_types.h:227
ADIS device initialization parameters.
Definition: adis.h:306
int adis_write_bias_corr_en_xa(struct adis_dev *adis, uint32_t bias_corr_en_xa)
Write x axis accelerometer bias correction enable bit value.
Definition: adis.c:3520
int adis_read_fir_bank_sel_ya(struct adis_dev *adis, uint32_t *fir_bank_sel_ya)
Read y axis accelerometer filter bank selection encoded value.
Definition: adis.c:2345
int adis_read_sync_polarity(struct adis_dev *adis, uint32_t *sync_polarity)
Read sync polarity encoded value.
Definition: adis.c:2699
@ ADIS_BURST_SEL
Definition: iio_adis_internals.h:141
int adis_read_xg_bias(struct adis_dev *adis, int32_t *xg_bias)
Read raw gyroscope offset correction on x axis.
Definition: adis.c:1566
@ ADIS_FIFO_WM_LVL
Definition: iio_adis_internals.h:116
int adis_read_burst_sel(struct adis_dev *adis, uint32_t *burst_sel)
Read burst selection encoded value.
Definition: adis.c:3183
int adis_write_fir_en_xg(struct adis_dev *adis, uint32_t fir_en_xg)
Write x axis gyroscope filter enable bit value.
Definition: adis.c:2081
@ ADIS_ALARM_IND_POLARITY
Definition: iio_adis_internals.h:128
int adis_read_usr_scr_4(struct adis_dev *adis, uint32_t *usr_scr_4)
Read user scratch register 4 value.
Definition: adis.c:3890
@ ADIS_FIRM_REV
Definition: iio_adis_internals.h:182
@ ADIS_BIAS_CORR_EN_YG
Definition: iio_adis_internals.h:165
int adis_write_usr_scr_1(struct adis_dev *adis, uint32_t usr_scr_1)
Write user scratch register 1 value.
Definition: adis.c:3835
ADIS burst data structure.
Definition: adis.h:248
Structure holding channel attributess.
Definition: iio_types.h:103
int adis_read_bias_corr_tbc(struct adis_dev *adis, uint32_t *bias_corr_tbc)
Read time base control value.
Definition: adis.c:3401
int adis_write_bias_corr_tbc(struct adis_dev *adis, uint32_t bias_corr_tbc)
Write time base control value.
Definition: adis.c:3413
@ ADIS_FIFO_EN
Definition: iio_adis_internals.h:112
int adis_read_diag_accl_failure(struct adis_dev *adis, uint32_t *accl_failure)
Diagnosis: read accelerometer self test error flag value.
Definition: adis.c:855
@ ADIS_SYNC_LINE_SEL
Definition: iio_adis_internals.h:125
@ ADIS_USR_SCR_2
Definition: iio_adis_internals.h:188
@ ADIS_CMD_FACT_CALIB_RESTORE
Definition: iio_adis_internals.h:172
int adis_read_z_deltang(struct adis_dev *adis, int32_t *z_deltang)
Read raw delta angle data on z axis.
Definition: adis.c:1468
int adis_get_accl_scale(struct adis_dev *adis, struct adis_scale_fractional *accl_scale)
Read adis device acceleration scale in fractional form.
Definition: adis.c:4161
@ ADIS_DR_POLARITY
Definition: iio_adis_internals.h:122
int adis_read_xa_bias(struct adis_dev *adis, int32_t *xa_bias)
Read raw acceleration offset correction on x axis.
Definition: adis.c:1632
int iio_trig_disable(void *trig)
Disable system interrupt which is linked to the given trigger.
Definition: iio_trigger.c:127
uint32_t dividend
Definition: adis.h:229
int adis_read_y_gyro(struct adis_dev *adis, int32_t *y_gyro)
Read raw gyroscope data on y axis.
Definition: adis.c:1294
int adis_iio_write_debug_attrs(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the write request for debug attributes.
Definition: iio_adis.c:1221
int adis_read_usr_scr_3(struct adis_dev *adis, uint32_t *usr_scr_3)
Read user scratch register 3 value.
Definition: adis.c:3868
uint8_t storagebits
Definition: iio_types.h:157
@ IIO_VAL_FRACTIONAL
Definition: iio_types.h:55
#define ADIS_BURST_DATA_SEL_0_CHN_MASK
Definition: iio_adis.c:51
int adis_read_usr_scr_1(struct adis_dev *adis, uint32_t *usr_scr_1)
Read user scratch register 1 value.
Definition: adis.c:3824
Header file of Delay functions.
int adis_write_usr_scr_4(struct adis_dev *adis, uint32_t usr_scr_4)
Write user scratch register 4 value.
Definition: adis.c:3901
int adis_read_x_gyro(struct adis_dev *adis, int32_t *x_gyro)
Read raw gyroscope data on x axis.
Definition: adis.c:1275
int adis_read_diag_int_snsr_supply_err(struct adis_dev *adis, uint32_t *int_snsr_supply_err)
Diagnosis: read internal sensor supply error flag value.
Definition: adis.c:1211
int adis_write_lpf(struct adis_dev *adis, enum adis_chan_type chan, enum adis_axis_type axis, uint32_t freq)
Configure filter for the given filter frequency.
Definition: adis.c:2032
int adis_read_yg_bias(struct adis_dev *adis, int32_t *yg_bias)
Read raw gyroscope offset correction on y axis.
Definition: adis.c:1588
@ ADIS_DIO_1_LVL
Definition: iio_adis_internals.h:134
int adis_write_ya_bias(struct adis_dev *adis, int32_t ya_bias)
Write raw acceleration offset correction on y axis.
Definition: adis.c:1665
int adis_write_fir_bank_sel_zg(struct adis_dev *adis, uint32_t fir_bank_sel_zg)
Write z axis gyroscope filter bank selection encoded value.
Definition: adis.c:2297
@ ADIS_DELTA_VEL_Y
Definition: iio_adis_internals.h:64
@ ADIS_ACCL_CHAN
Definition: adis.h:115
int adis_write_sync_4khz(struct adis_dev *adis, uint32_t sync_4khz)
Write 4khz internal sync enable bit value.
Definition: adis.c:3306
int adis_cmd_fls_mem_test(struct adis_dev *adis)
Command: flash memory test.
Definition: adis.c:3653
@ ADIS_FILT_SIZE_VAR_B
Definition: iio_adis_internals.h:118
int adis_write_xg_scale(struct adis_dev *adis, int32_t xg_scale)
Write raw gyroscope scale adjustment on x axis.
Definition: adis.c:1709
int adis_write_zg_bias(struct adis_dev *adis, int32_t zg_bias)
Write raw gyroscope offset correction on z axis.
Definition: adis.c:1621
@ ADIS_DIAG_LOST_SAMPLES_COUNT
Definition: iio_adis_internals.h:104
Definition: ad9361_util.h:69
@ ADIS_SYNC_4KHZ
Definition: iio_adis_internals.h:144
int adis_read_time_stamp(struct adis_dev *adis, uint32_t *time_stamp)
Read raw time stamp data.
Definition: adis.c:1408
int adis_read_dr_polarity(struct adis_dev *adis, uint32_t *dr_polarity)
Read data ready polarity encoded value.
Definition: adis.c:2589
@ ADIS16475_1
Definition: adis.h:82
int adis_read_firm_d(struct adis_dev *adis, uint32_t *firm_d)
Read firmware factory configuration day value.
Definition: adis.c:3747
int adis_read_diag_gyro1_failure(struct adis_dev *adis, uint32_t *gyro1_failure)
Diagnosis: read gyroscope1 self test error flag value.
Definition: adis.c:815
uint32_t divisor
Definition: adis.h:231
int adis_read_fir_bank_sel_xa(struct adis_dev *adis, uint32_t *fir_bank_sel_xa)
Read x axis accelerometer filter bank selection encoded value.
Definition: adis.c:2313
int adis_write_yg_scale(struct adis_dev *adis, int32_t yg_scale)
Write raw gyroscope scale adjustment on y axis.
Definition: adis.c:1732
int adis_write_burst32(struct adis_dev *adis, uint32_t burst32)
Write burst32 enable bit value.
Definition: adis.c:3242
@ ADIS16467_1
Definition: adis.h:78
@ ADIS_FIR_EN_ZA
Definition: iio_adis_internals.h:152
bool has_fifo
Definition: iio_adis_internals.h:238
int adis_read_fifo_en(struct adis_dev *adis, uint32_t *fifo_en)
Definition: adis.c:1836
void * no_os_calloc(size_t nitems, size_t size)
Allocate memory and return a pointer to it, set memory to 0.
Definition: chibios_alloc.c:54
#define NO_OS_ARRAY_SIZE(x)
Definition: no_os_util.h:49
@ ADIS_PROC_REV
Definition: iio_adis_internals.h:180
Implementation of adis1646x.h.
int adis_read_diag_z_axis_gyro_failure(struct adis_dev *adis, uint32_t *z_axis_gyro_failure)
Diagnosis: read Z-Axis Gyroscope failure flag value.
Definition: adis.c:917
@ ADIS_EXT_CLK_FREQ
Definition: iio_adis_internals.h:192
int adis_read_timestamp32(struct adis_dev *adis, uint32_t *timestamp32)
Read timestamp32 enable bit value.
Definition: adis.c:3263
@ ADIS_DIAG_ACCL_FAILURE
Definition: iio_adis_internals.h:83
int adis_write_burst_sel(struct adis_dev *adis, uint32_t burst_sel)
Write burst selection encoded value.
Definition: adis.c:3202
int adis_read_usr_scr_2(struct adis_dev *adis, uint32_t *usr_scr_2)
Read user scratch register 2 value.
Definition: adis.c:3846
int adis_read_x_deltang(struct adis_dev *adis, int32_t *x_deltang)
Read raw delta angle data on x axis.
Definition: adis.c:1430
int adis_get_anglvel_scale(struct adis_dev *adis, struct adis_scale_fractional *anglvel_scale)
Read adis device gyroscope scale in fractional form.
Definition: adis.c:4145
int adis_write_reg(struct adis_dev *adis, uint32_t reg, uint32_t val, uint32_t size)
Write N bytes to register.
Definition: adis.c:305
int adis_write_dr_enable(struct adis_dev *adis, uint32_t dr_enable)
Write data ready enable encoded value.
Definition: adis.c:2636
int adis_write_fir_en_zg(struct adis_dev *adis, uint32_t fir_en_zg)
Write z axis gyroscope filter enable bit value.
Definition: adis.c:2129
int adis_read_x_accl(struct adis_dev *adis, int32_t *x_accl)
Read raw acceleration data on x axis.
Definition: adis.c:1332
@ ADIS_LOT_NUM
Definition: iio_adis_internals.h:186
@ ADIS_ACCEL_X
Definition: iio_adis_internals.h:56
@ ADIS_DIAG_TEMP_ERR
Definition: iio_adis_internals.h:93
int adis_read_burst_data(struct adis_dev *adis, struct adis_burst_data *data, bool burst32, uint8_t burst_sel, bool fifo_pop, bool crc_check)
Read burst data.
Definition: adis.c:3977
int adis_write_fir_bank_sel_xg(struct adis_dev *adis, uint32_t fir_bank_sel_xg)
Write x axis gyroscope filter bank selection encoded value.
Definition: adis.c:2233
@ ADIS_SYNC_POLARITY
Definition: iio_adis_internals.h:124
@ ADIS16467_2
Definition: adis.h:79
@ ADIS_DATA_CNTR
Definition: iio_adis_internals.h:107
int adis_read_spi_chksum(struct adis_dev *adis, uint32_t *checksum)
Read current sample SPI transaction checksum.
Definition: adis.c:1555
ADIS fractional log2 scale format structure; scale = dividend/2^power.
Definition: adis.h:237
int adis_read_fifo_overflow(struct adis_dev *adis, uint32_t *fifo_overflow)
Read FIFO overflow bit value.
Definition: adis.c:1866
int adis_write_bias_corr_en_zg(struct adis_dev *adis, uint32_t bias_corr_en_zg)
Write z axis gyroscope bias correction enable bit value.
Definition: adis.c:3494
int adis_read_accl_fir_enable(struct adis_dev *adis, uint32_t *accl_fir_enable)
Read accelerometer FIR filter control bit value.
Definition: adis.c:3063
uint16_t dec_rate_max
Definition: adis_internals.h:450
@ ADIS_GYRO_Y
Definition: iio_adis_internals.h:54
@ ADIS_FIR_EN_ZG
Definition: iio_adis_internals.h:149
int adis_write_gpio_dir(struct adis_dev *adis, uint8_t dio_nb, uint32_t dir)
Write gpio direction configuration.
Definition: adis.c:2968
@ ADIS_DIO_2_DIR
Definition: iio_adis_internals.h:131
int adis_iio_write_calibbias(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the write request for calibbias attribute.
Definition: iio_adis.c:344
ADIS IIO device descriptor structure.
Definition: iio_adis_internals.h:218
#define ADIS_HAS_BURST32
Definition: adis_internals.h:38
@ IIO_SHARED_BY_ALL
Definition: iio_types.h:122
uint32_t no_os_lowest_common_multiple(uint32_t a, uint32_t b)
uint32_t power
Definition: adis.h:241
@ ADIS_FIR_BANK_SEL_XA
Definition: iio_adis_internals.h:156
int adis_write_xa_scale(struct adis_dev *adis, int32_t xa_scale)
Write raw acceleration scale adjustment on x axis.
Definition: adis.c:1778
@ ADIS_DIAG_Y_AXIS_ACCL_FAILURE
Definition: iio_adis_internals.h:88
@ ADIS16465_3
Definition: adis.h:77
uint16_t data[26]
Definition: iio_adis_internals.h:236
int adis_init(struct adis_dev **adis, const struct adis_init_param *ip)
Initialize adis device.
Definition: adis.c:99
int adis_read_x_deltvel(struct adis_dev *adis, int32_t *x_deltvel)
Read raw delta velocity data on x axis.
Definition: adis.c:1487
int adis_read_lpf(struct adis_dev *adis, enum adis_chan_type chan, enum adis_axis_type axis, uint32_t *freq)
Read configured filter frequency.
Definition: adis.c:2000
int adis_read_z_accl(struct adis_dev *adis, int32_t *z_accl)
Read raw acceleration data on z axis.
Definition: adis.c:1370
int adis_read_y_accl(struct adis_dev *adis, int32_t *y_accl)
Read raw acceleration data on y axis.
Definition: adis.c:1351
int adis_read_diag_y_axis_gyro_failure(struct adis_dev *adis, uint32_t *y_axis_gyro_failure)
Diagnosis: read Y-Axis Gyroscope failure flag value.
Definition: adis.c:896
@ ADIS_BIAS_CORR_EN_ZG
Definition: iio_adis_internals.h:166
@ ADIS_SPI_CHKSUM
Definition: iio_adis_internals.h:110
int adis_cmd_bias_corr_update(struct adis_dev *adis)
Command: bias correction update.
Definition: adis.c:3583
ADIS device descriptor structure.
Definition: adis.h:270
@ ADIS_PROD_ID
Definition: iio_adis_internals.h:184
int adis_read_diag_temp_err(struct adis_dev *adis, uint32_t *temp_err)
Diagnosis: read temperature error flag value.
Definition: adis.c:1064
int adis_read_diag_reg_nvm_err(struct adis_dev *adis, uint32_t *reg_nvm_err)
Diagnosis: read register NVM error flag value.
Definition: adis.c:1127
int adis_read_fifo_wm_int_en(struct adis_dev *adis, uint32_t *fifo_wm_int_en)
Read FIFO watermark interrupt enable bit value.
Definition: adis.c:1890
uint32_t max_freq
Definition: adis_internals.h:104
@ ADIS_X_AXIS
Definition: adis.h:126
const char * name
Definition: iio_types.h:131
int adis_read_proc_rev(struct adis_dev *adis, uint32_t *proc_rev)
Read processor revision value.
Definition: adis.c:3725
int adis_write_ya_scale(struct adis_dev *adis, int32_t ya_scale)
Write raw acceleration scale adjustment on y axis.
Definition: adis.c:1801
int adis_read_sync_mode(struct adis_dev *adis, uint32_t *sync_mode)
Read synchronization mode encoded value.
Definition: adis.c:2734
@ ADIS_BIAS_CORR_EN_ZA
Definition: iio_adis_internals.h:169
@ ADIS_DELTA_ANGL_X
Definition: iio_adis_internals.h:60
void adis_read_diag_fls_mem_wr_cnt_exceed(struct adis_dev *adis, uint32_t *fls_mem_wr_cnt_exceed)
Diagnosis: read flash memory write counts exceeded flag value.
Definition: adis.c:1262
@ ADIS_DIAG_WDG_TIMER_FLAG
Definition: iio_adis_internals.h:97
@ ADIS_SENS_BW
Definition: iio_adis_internals.h:138
int adis_read_xa_scale(struct adis_dev *adis, int32_t *xa_scale)
Read raw acceleration scale adjustment on x axis.
Definition: adis.c:1767
@ ADIS_TIMESTAMP32
Definition: iio_adis_internals.h:143
int adis_read_gyro_fir_enable(struct adis_dev *adis, uint32_t *gyro_fir_enable)
Read gyroscope FIR filter control bit value.
Definition: adis.c:3087
int adis_cmd_fifo_flush(struct adis_dev *adis)
Command: fifo flush.
Definition: adis.c:3672
uint32_t ext_clk
Definition: adis.h:292
@ ADIS_DIAG_Z_AXIS_GYRO_FAILURE
Definition: iio_adis_internals.h:86
@ ADIS_DIAG_DATA_PATH_OVERRUN
Definition: iio_adis_internals.h:74
const struct adis_chip_info * info
Definition: adis.h:276
int adis_read_alarm_polarity(struct adis_dev *adis, uint32_t *alarm_polarity)
Read alarm polarity encoded value.
Definition: adis.c:2833
@ ADIS_DIAG_ADUC_MCU_FAULT
Definition: iio_adis_internals.h:90
@ ADIS_CMD_FLS_MEM_UPDATE
Definition: iio_adis_internals.h:174
int adis_read_sens_bw(struct adis_dev *adis, uint32_t *sens_bw)
Read internal sensor bandwidth encoded value.
Definition: adis.c:3033
int adis_write_dr_selection(struct adis_dev *adis, uint32_t dr_selection)
Write data ready selection encoded value.
Definition: adis.c:2569
int adis_read_temp_out(struct adis_dev *adis, int32_t *temp_out)
Read raw temperature data.
Definition: adis.c:1389
Implementation of iio_adis1646x.h.
int adis_write_alarm_selection(struct adis_dev *adis, uint32_t alarm_selection)
Write alarm selection encoded value.
Definition: adis.c:2813
@ ADIS_DELTA_VEL_X
Definition: iio_adis_internals.h:63
ADIS fractional scale format structure; scale = dividend/divisor.
Definition: adis.h:227
@ ADIS_BIAS_CORR_EN_XA
Definition: iio_adis_internals.h:167
int adis_write_fir_bank_sel_ya(struct adis_dev *adis, uint32_t fir_bank_sel_ya)
Write y axis accelerometer filter bank selection encoded value.
Definition: adis.c:2361
@ ADIS_GYRO_X
Definition: iio_adis_internals.h:53
int iio_trig_enable(void *trig)
Enable system interrupt which is linked to the given trigger.
Definition: iio_trigger.c:110
int adis_read_fls_mem_wr_cntr(struct adis_dev *adis, uint32_t *fls_mem_wr_cntr)
Read flash memory write cycle counter value.
Definition: adis.c:3912
@ ADIS_FIR_EN_YA
Definition: iio_adis_internals.h:151
Internal include file used for specific chip IIO driver definitions which are not useful for the user...
int adis_write_fifo_wm_int_en(struct adis_dev *adis, uint32_t fifo_wm_int_en)
Write FIFO watermark interrupt enable bit value.
Definition: adis.c:1902
int adis_read_fir_en_zg(struct adis_dev *adis, uint32_t *fir_en_zg)
Read z axis gyroscope filter enable bit value.
Definition: adis.c:2117
int adis_read_z_gyro(struct adis_dev *adis, int32_t *z_gyro)
Read raw gyroscope data on z axis.
Definition: adis.c:1313
int adis_get_temp_scale(struct adis_dev *adis, struct adis_scale_fractional *temp_scale)
Read adis device temperature scale in fractional form.
Definition: adis.c:4209
int adis_read_diag_fls_mem_update_failure(struct adis_dev *adis, uint32_t *fls_mem_update_failure)
Diagnosis: read flash memory update error flag value.
Definition: adis.c:693
@ ADIS_TIME_STAMP
Definition: iio_adis_internals.h:106
int adis_write_xg_bias(struct adis_dev *adis, int32_t xg_bias)
Write raw gyroscope offset correction on x axis.
Definition: adis.c:1577
@ ADIS_SYNC_MODE
Definition: iio_adis_internals.h:126
int adis_iio_trigger_handler_with_fifo(struct iio_device_data *dev_data)
Handles trigger: reads all available samples in FIFO and writes them to the buffer.
Definition: iio_adis.c:1744
@ ADIS_DIAG_OVERRANGE
Definition: iio_adis_internals.h:92
@ ADIS_DIAG_GYRO1_FAILURE
Definition: iio_adis_internals.h:81
Implementation of adis.h.
Structure holding pointers to show and store functions.
Definition: iio_types.h:129
@ ADIS_DIAG_CONFIG_CALIB_CRC_ERR
Definition: iio_adis_internals.h:91
int adis_read_firm_y(struct adis_dev *adis, uint32_t *firm_y)
Read firmware factory configuration year value.
Definition: adis.c:3769
int adis_read_dec_rate(struct adis_dev *adis, uint32_t *dec_rate)
Read decimation rate value.
Definition: adis.c:3368
@ ADIS_CMD_FLS_MEM_TEST
Definition: iio_adis_internals.h:175
int adis_write_sync_polarity(struct adis_dev *adis, uint32_t sync_polarity)
Write sync polarity encoded value.
Definition: adis.c:2711
int adis_read_diag_z_axis_accl_failure(struct adis_dev *adis, uint32_t *z_axis_accl_failure)
Diagnosis: read Z-Axis Accelerometer failure flag value.
Definition: adis.c:980
int adis_iio_read_reg(struct adis_iio_dev *device, uint32_t reg, uint32_t *readval)
Wrapper for reading adis register.
Definition: iio_adis.c:69
Definition: iio_types.h:209
@ ADIS_DIAG_CHECKSUM_ERR
Definition: iio_adis_internals.h:102
@ ADIS_Y_AXIS
Definition: adis.h:127
uint32_t active_mask
Definition: iio_types.h:211
int adis_read_bias_corr_en_ya(struct adis_dev *adis, uint32_t *bias_corr_en_ya)
Read y axis accelerometer bias correction enable bit value.
Definition: adis.c:3533
int adis_read_diag_gyro2_failure(struct adis_dev *adis, uint32_t *gyro2_failure)
Diagnosis: read gyroscope2 self test error flag value.
Definition: adis.c:835
int adis_write_alarm_enable(struct adis_dev *adis, uint32_t alarm_enable)
Write alarm enable encoded value.
Definition: adis.c:2880
int adis_write_za_bias(struct adis_dev *adis, int32_t za_bias)
Write raw acceleration offset correction on z axis.
Definition: adis.c:1687
@ ADIS_DELTA_VEL_Z
Definition: iio_adis_internals.h:65
const char * rang_mdl_txt
Definition: iio_adis_internals.h:240
int adis_read_xg_scale(struct adis_dev *adis, int32_t *xg_scale)
Read raw gyroscope scale adjustment on x axis.
Definition: adis.c:1698
int adis_write_gyro_fir_enable(struct adis_dev *adis, uint32_t gyro_fir_enable)
Write gyroscope FIR filter control bit value.
Definition: adis.c:3099
struct iio_attribute adis_iio_accel_attrs[]
Definition: iio_adis.c:1837
@ ADIS_FIR_BANK_SEL_YG
Definition: iio_adis_internals.h:154
int32_t iio_parse_value(char *buf, enum iio_val fmt, int32_t *val, int32_t *val2)
Definition: iio.c:630
@ ADIS_FIR_BANK_SEL_ZA
Definition: iio_adis_internals.h:158
@ ADIS_DELTA_ANGL_Y
Definition: iio_adis_internals.h:61
int adis_read_fir_bank_sel_yg(struct adis_dev *adis, uint32_t *fir_bank_sel_yg)
Read y axis gyroscope filter bank selection encoded value.
Definition: adis.c:2249
struct iio_attribute adis_iio_anglvel_attrs[]
Definition: iio_adis.c:1819
int adis_iio_write_calibscale(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the write request for calibscale attribute.
Definition: iio_adis.c:449
int adis_read_linear_accl_comp(struct adis_dev *adis, uint32_t *linear_accl_comp)
Read linear acceleration compensation enable bit value.
Definition: adis.c:3148
int adis_read_y_deltvel(struct adis_dev *adis, int32_t *y_deltvel)
Read raw delta velocity data on y axis.
Definition: adis.c:1506
int adis_iio_post_disable(void *dev, uint32_t mask)
API to be called after trigger is disabled.
Definition: iio_adis.c:1472
const uint32_t flags
Definition: adis_internals.h:434
int adis_read_fifo_cnt(struct adis_dev *adis, uint32_t *fifo_cnt)
Read output FIFO sample count.
Definition: adis.c:1544
@ ADIS_DIAG_INT_SNSR_SUPPLY_ERR
Definition: iio_adis_internals.h:100
int adis_write_bias_corr_en_za(struct adis_dev *adis, uint32_t bias_corr_en_za)
Write z axis accelerometer bias correction enable bit value.
Definition: adis.c:3572
int adis_write_za_scale(struct adis_dev *adis, int32_t za_scale)
Write raw acceleration scale adjustment on z axis.
Definition: adis.c:1824
int adis_read_bias_corr_en_zg(struct adis_dev *adis, uint32_t *bias_corr_en_zg)
Read z axis gyroscope bias correction enable bit value.
Definition: adis.c:3481
int adis_write_bias_corr_en_ya(struct adis_dev *adis, uint32_t bias_corr_en_ya)
Write y axis accelerometer bias correction enable bit value.
Definition: adis.c:3546
@ ADIS_Z_AXIS
Definition: adis.h:128
@ ADIS_DIO_4_DIR
Definition: iio_adis_internals.h:133
@ ADIS_DIO_3_LVL
Definition: iio_adis_internals.h:136
@ ADIS_FIFO_CNT
Definition: iio_adis_internals.h:109
@ ADIS_DIAG_REG_NVM_ERR
Definition: iio_adis_internals.h:96
int adis_cmd_fact_calib_restore(struct adis_dev *adis)
Command: factory calibration restore.
Definition: adis.c:3594
int adis_read_fir_bank_sel_xg(struct adis_dev *adis, uint32_t *fir_bank_sel_xg)
Read x axis gyroscope filter bank selection encoded value.
Definition: adis.c:2217
int adis_read_diag_spi_comm_err(struct adis_dev *adis, uint32_t *spi_comm_err)
Diagnosis: read spi communication error flag value.
Definition: adis.c:714
struct iio_attribute adis_iio_delta_angl_attrs[]
Definition: iio_adis.c:1867
struct iio_buffer * buffer
Definition: iio_types.h:228
int adis_read_diag_int_proc_supply_err(struct adis_dev *adis, uint32_t *int_proc_supply_err)
Diagnosis: read internal processor supply error flag value.
Definition: adis.c:1169
int adis_write_alarm_polarity(struct adis_dev *adis, uint32_t alarm_polarity)
Write alarm polarity encoded value.
Definition: adis.c:2845
int adis_iio_trigger_handler(struct iio_device_data *dev_data)
Handles trigger: reads one data-set and writes it to the buffer.
Definition: iio_adis.c:1722
int adis_iio_read_lpf(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the read request for lpf attribute.
Definition: iio_adis.c:498
@ ADIS_DIAG_SNSR_FAILURE
Definition: iio_adis_internals.h:78
@ ADIS_DEC_RATE
Definition: iio_adis_internals.h:161
@ ADIS_DIO_4_LVL
Definition: iio_adis_internals.h:137
@ ADIS_DIAG_Z_AXIS_ACCL_FAILURE
Definition: iio_adis_internals.h:89
int adis_read_pt_of_perc_algnmt(struct adis_dev *adis, uint32_t *pt_of_perc_algnmt)
Read point of percussion alignment enable bit value.
Definition: adis.c:3112
#define ADIS1646X_ID_NO_OFFSET(x)
Definition: adis1646x.h:47
int adis_read_diag_standby_mode(struct adis_dev *adis, uint32_t *standby_mode)
Diagnosis: read standby mode flag value.
Definition: adis.c:734
@ ADIS_DIAG_GYRO2_FAILURE
Definition: iio_adis_internals.h:82
int adis_iio_read_sampling_freq(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the read request for sampling frequency attribute.
Definition: iio_adis.c:657
int iio_format_value(char *buf, uint32_t len, enum iio_val fmt, int32_t size, int32_t *vals)
Definition: iio.c:686
int adis_read_fir_en_yg(struct adis_dev *adis, uint32_t *fir_en_yg)
Read y axis gyroscope filter enable bit value.
Definition: adis.c:2093
@ ADIS_DIAG_SNSR_INIT_FAILURE
Definition: iio_adis_internals.h:73
@ ADIS_FIR_EN_YG
Definition: iio_adis_internals.h:148
uint32_t address
Definition: iio_types.h:113
int adis_read_filt_size_var_b(struct adis_dev *adis, uint32_t *filt_size_var_b)
Read filter size variable B value.
Definition: adis.c:1962
int adis_read_ya_scale(struct adis_dev *adis, int32_t *ya_scale)
Read raw acceleration scale adjustment on y axis.
Definition: adis.c:1790
int adis_read_alarm_selection(struct adis_dev *adis, uint32_t *alarm_selection)
Read alarm selection encoded value.
Definition: adis.c:2797
@ ADIS_NUM_CHAN
Definition: iio_adis_internals.h:66
int adis_get_sync_clk_freq(struct adis_dev *adis, uint32_t *clk_freq)
Read adis synchronization clock frequency value in Hertz.
Definition: adis.c:4123
@ ADIS_UP_SCALE
Definition: iio_adis_internals.h:160
#define ADIS_DELTA_ANGL_CHAN_NO_SCAN(mod, idx, attr)
Definition: iio_adis_internals.h:278
uint16_t num_ch
Definition: iio_types.h:252
struct scan_type * scan_type
Definition: iio_types.h:184
int adis_get_temp_offset(struct adis_dev *adis, int *temp_offset)
Read adis device temperature offset in integer.
Definition: adis.c:4225
@ ADIS_ACCL_FIR_ENABLE
Definition: iio_adis_internals.h:146
void no_os_free(void *ptr)
Deallocate memory previously allocated by a call to no_os_calloc or no_os_malloc.
Definition: chibios_alloc.c:69
int adis_iio_write_reg(struct adis_iio_dev *device, uint32_t reg, uint32_t writeval)
Wrapper for writing to adis register.
Definition: iio_adis.c:82
@ IIO_TEMP
Definition: iio_types.h:69
enum iio_chan_type type
Definition: iio_types.h:109
int adis_read_diag_x_axis_gyro_failure(struct adis_dev *adis, uint32_t *x_axis_gyro_failure)
Diagnosis: read X-Axis Gyroscope failure flag value.
Definition: adis.c:875
int adis_read_gpio_lvl(struct adis_dev *adis, uint8_t dio_nb, uint32_t *level)
Read gpio configured data level.
Definition: adis.c:2938
@ ADIS_DIAG_MEM_FAILURE
Definition: iio_adis_internals.h:79
@ ADIS_FIR_BANK_SEL_XG
Definition: iio_adis_internals.h:153
@ ADIS_FIFO_WM_INT_POL
Definition: iio_adis_internals.h:115
@ ADIS_FLS_MEM_WR_CNTR
Definition: iio_adis_internals.h:191
int adis_iio_read_calibbias(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the read request for calibbias attribute.
Definition: iio_adis.c:288
@ ADIS_DIAG_CLK_ERR
Definition: iio_adis_internals.h:80
@ ADIS_DIAG_Y_AXIS_GYRO_FAILURE
Definition: iio_adis_internals.h:85
int adis_write_fir_bank_sel_xa(struct adis_dev *adis, uint32_t fir_bank_sel_xa)
Write x axis accelerometer filter bank selection encoded value.
Definition: adis.c:2329
int adis_write_fifo_wm_lvl(struct adis_dev *adis, uint32_t fifo_wm_lvl)
Write FIFO watermark threshold level value.
Definition: adis.c:1950
int adis_read_yg_scale(struct adis_dev *adis, int32_t *yg_scale)
Read raw gyroscope scale adjustment on y axis.
Definition: adis.c:1721
int adis_read_zg_scale(struct adis_dev *adis, int32_t *zg_scale)
Read raw gyroscope scale adjustment on z axis.
Definition: adis.c:1744
int adis_read_fir_en_ya(struct adis_dev *adis, uint32_t *fir_en_ya)
Read y axis accelerometer filter enable bit value.
Definition: adis.c:2165
void no_os_udelay(uint32_t usecs)
Wait until usecs microseconds passed.
Definition: aducm3029_delay.c:114
int adis_read_sync_4khz(struct adis_dev *adis, uint32_t *sync_4khz)
Read 4khz internal sync enable bit value.
Definition: adis.c:3295
#define NO_OS_U16_MAX
Definition: no_os_util.h:112
#define NULL
Definition: wrapper.h:64
@ ADIS_DIAG_INT_PROC_SUPPLY_ERR
Definition: iio_adis_internals.h:98
@ ADIS16475_2
Definition: adis.h:83
int adis_write_xa_bias(struct adis_dev *adis, int32_t xa_bias)
Write raw acceleration offset correction on x axis.
Definition: adis.c:1643
int adis_read_diag_y_axis_accl_failure(struct adis_dev *adis, uint32_t *y_axis_accl_failure)
Diagnosis: read Y-Axis Accelerometer failure flag value.
Definition: adis.c:959
int adis_read_fifo_wm_lvl(struct adis_dev *adis, uint32_t *fifo_wm_lvl)
Read FIFO watermark threshold level value.
Definition: adis.c:1938
int adis_write_bias_corr_en_xg(struct adis_dev *adis, uint32_t bias_corr_en_xg)
Write x axis gyroscope bias correction enable bit value.
Definition: adis.c:3442
int adis_iio_read_scale(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the read request for scale attribute.
Definition: iio_adis.c:174
@ ADIS_CMD_FIFO_FLUSH
Definition: iio_adis_internals.h:176
int adis_read_reg(struct adis_dev *adis, uint32_t reg, uint32_t *val, uint32_t size)
Read N bytes from register.
Definition: adis.c:211
int adis_read_data_cntr(struct adis_dev *adis, uint32_t *data_cntr)
Read data counter value.
Definition: adis.c:1419
@ ADIS_DIAG_X_AXIS_ACCL_FAILURE
Definition: iio_adis_internals.h:87
@ ADIS_SERIAL_NUM
Definition: iio_adis_internals.h:185
struct ad7616_init_param init_param
Definition: ad7616_sdz.c:113
int adis_read_za_scale(struct adis_dev *adis, int32_t *za_scale)
Read raw acceleration scale adjustment on z axis.
Definition: adis.c:1813
@ ADIS_LINEAR_ACCL_COMP
Definition: iio_adis_internals.h:140
@ ADIS_DIAG_SPI_COMM_ERR
Definition: iio_adis_internals.h:76
#define ADIS_BURST_DATA_SEL_1_CHN_MASK
Definition: iio_adis.c:52
Structure holding channels and attributes of a device.
Definition: iio_types.h:247
int adis_read_diag_data_path_overrun(struct adis_dev *adis, uint32_t *data_path_overrun_err)
Diagnosis: read data path overrun flag value.
Definition: adis.c:672
int adis_write_filt_size_var_b(struct adis_dev *adis, uint32_t filt_size_var_b)
Write filter size variable B value.
Definition: adis.c:1974
@ ADIS_USR_SCR_3
Definition: iio_adis_internals.h:189
int adis1646x_iio_init(struct adis_iio_dev **iio_dev, struct adis_init_param *init_param)
Initialize adis1646x iio device.
Definition: iio_adis1646x.c:360
int adis_write_sync_mode(struct adis_dev *adis, uint32_t sync_mode, uint32_t ext_clk)
Update synchronization mode.
Definition: adis.c:2750
struct iio_attribute adis_iio_temp_attrs[]
Definition: iio_adis.c:1855
int adis_iio_read_calibscale(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the read request for calibscale attribute.
Definition: iio_adis.c:393
int adis_read_bias_corr_en_xg(struct adis_dev *adis, uint32_t *bias_corr_en_xg)
Read x axis gyroscope bias correction enable bit value.
Definition: adis.c:3429
@ ADIS_DIAG_STANDBY_MODE
Definition: iio_adis_internals.h:77
int adis_write_fifo_overflow(struct adis_dev *adis, uint32_t fifo_overflow)
Write FIFO overflow bit value.
Definition: adis.c:1878
int adis_read_burst32(struct adis_dev *adis, uint32_t *burst32)
Read burst32 enable bit value.
Definition: adis.c:3223
int adis_write_usr_scr_3(struct adis_dev *adis, uint32_t usr_scr_3)
Write user scratch register 3 value.
Definition: adis.c:3879
int adis_read_ya_bias(struct adis_dev *adis, int32_t *ya_bias)
Read raw acceleration offset correction on y axis.
Definition: adis.c:1654
int adis_iio_read_raw(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the read request for raw attribute.
Definition: iio_adis.c:97
@ ADIS_DIO_1_DIR
Definition: iio_adis_internals.h:130
@ ADIS_DIAG_X_AXIS_GYRO_FAILURE
Definition: iio_adis_internals.h:84
int adis_write_fir_bank_sel_za(struct adis_dev *adis, uint32_t fir_bank_sel_za)
Write z axis accelerometer filter bank selection encoded value.
Definition: adis.c:2393
@ ADIS_BIAS_CORR_EN_XG
Definition: iio_adis_internals.h:164
int adis_cmd_sw_res(struct adis_dev *adis)
Command: software reset.
Definition: adis.c:3683
@ ADIS_BURST32
Definition: iio_adis_internals.h:142
int adis_write_fir_en_ya(struct adis_dev *adis, uint32_t fir_en_ya)
Write y axis accelerometer filter enable bit value.
Definition: adis.c:2177
@ ADIS_DR_LINE_SEL
Definition: iio_adis_internals.h:123
@ ADIS_BIAS_CORR_EN_YA
Definition: iio_adis_internals.h:168
int adis_write_pt_of_perc_algnmt(struct adis_dev *adis, uint32_t pt_of_perc_algnmt)
Write point of percussion alignment enable bit value.
Definition: adis.c:3126
int adis_write_bias_corr_en_yg(struct adis_dev *adis, uint32_t bias_corr_en_yg)
Write y axis gyroscope bias correction enable bit value.
Definition: adis.c:3468
int adis_write_fir_bank_sel_yg(struct adis_dev *adis, uint32_t fir_bank_sel_yg)
Write y axis gyroscope filter bank selection encoded value.
Definition: adis.c:2265
uint32_t burst_size
Definition: iio_adis_internals.h:230
int adis_read_diag_wdg_timer_flag(struct adis_dev *adis, uint32_t *wdg_timer_flag)
Diagnosis: read watchdog timer flag value.
Definition: adis.c:1148
@ ADIS_DIAG_BOOT_MEMORY_FAILURE
Definition: iio_adis_internals.h:95
@ ADIS_BIAS_CORR_TBC
Definition: iio_adis_internals.h:163
@ ADIS_FIFO_OVERFLOW
Definition: iio_adis_internals.h:113
int adis_write_sens_bw(struct adis_dev *adis, uint32_t sens_bw)
Write internal sensor bandwidth encoded value.
Definition: adis.c:3044
int adis_read_dr_selection(struct adis_dev *adis, uint32_t *dr_selection)
Read data ready selection encoded value.
Definition: adis.c:2553
int adis_write_sync_selection(struct adis_dev *adis, uint32_t sync_selection)
Write sync selection encoded value.
Definition: adis.c:2679
@ ADIS_PT_OF_PERC_ALGNMT
Definition: iio_adis_internals.h:139
Definition: iio_types.h:151
struct adis_dev * adis_dev
Definition: iio_adis_internals.h:220
@ IIO_DELTA_ANGL
Definition: iio_types.h:79
int adis_read_diag_overrange(struct adis_dev *adis, uint32_t *overrange)
Diagnosis: read overrange for inertial sensors flag value.
Definition: adis.c:1043
int adis_read_bias_corr_en_yg(struct adis_dev *adis, uint32_t *bias_corr_en_yg)
Read y axis gyroscope bias correction enable bit value.
Definition: adis.c:3455
@ ADIS_FIRM_DATE
Definition: iio_adis_internals.h:183
int adis_cmd_fls_mem_update(struct adis_dev *adis)
Command: flash memory update.
Definition: adis.c:3632
int adis_get_deltavelocity_scale(struct adis_dev *adis, struct adis_scale_fractional_log2 *deltavelocity_scale)
Read adis device delta velocity scale in fractional form.
Definition: adis.c:4193
#define ADIS_SYNC_SCALED
Definition: adis.h:63
int adis_write_yg_bias(struct adis_dev *adis, int32_t yg_bias)
Write raw gyroscope offset correction on y axis.
Definition: adis.c:1599
Definition: iio_types.h:226
uint32_t data_cntr
Definition: iio_adis_internals.h:226
uint32_t dividend
Definition: adis.h:239
int adis_read_bias_corr_en_xa(struct adis_dev *adis, uint32_t *bias_corr_en_xa)
Read x axis accelerometer bias correction enable bit value.
Definition: adis.c:3507
uint32_t sampling_frequency
Definition: iio_adis_internals.h:228
int adis_write_fir_en_yg(struct adis_dev *adis, uint32_t fir_en_yg)
Write y axis gyroscope filter enable bit value.
Definition: adis.c:2105
@ ADIS16465_2
Definition: adis.h:76
int adis_read_dr_enable(struct adis_dev *adis, uint32_t *dr_enable)
Read data ready enable encoded value.
Definition: adis.c:2624
#define ADIS_DELTA_VEL_CHAN_NO_SCAN(mod, idx, attr)
Definition: iio_adis_internals.h:296
@ ADIS_DIAG_INT_REG_ERR
Definition: iio_adis_internals.h:101
int adis_read_alarm_enable(struct adis_dev *adis, uint32_t *alarm_enable)
Read alarm enable encoded value.
Definition: adis.c:2868
int adis_write_fifo_wm_int_pol(struct adis_dev *adis, uint32_t fifo_wm_int_pol)
Write FIFO watermark interrupt polarity bit value.
Definition: adis.c:1926
int adis_read_diag_ext_5v_supply_err(struct adis_dev *adis, uint32_t *ext_5v_supply_err)
Diagnosis: read external 5V supply error flag value.
Definition: adis.c:1190
void adis1646x_iio_remove(struct adis_iio_dev *desc)
Remove adis1646x iio device.
Definition: iio_adis1646x.c:393
int adis_read_diag_boot_memory_failure(struct adis_dev *adis, uint32_t *boot_memory_failure)
Diagnosis: read boot memory failure error flag value.
Definition: adis.c:1106
int adis1646x_iio_init(struct adis_iio_dev **iio_dev, struct adis_init_param *init_param)
Initialize adis1646x iio device.
Definition: iio_adis1646x.c:360
void adis_remove(struct adis_dev *adis)
Remove adis device.
Definition: adis.c:162
const struct adis_clk_freq_limit sampling_clk_limits
Definition: adis_internals.h:430
@ ADIS_CMD_SW_RES
Definition: iio_adis_internals.h:177
int adis_read_diag_mem_failure(struct adis_dev *adis, uint32_t *mem_failure)
Diagnosis: read flash memory test error flag value.
Definition: adis.c:775
@ ADIS_USR_SCR_1
Definition: iio_adis_internals.h:187
@ ADIS_ALARM_IND_LINE_SEL
Definition: iio_adis_internals.h:129
@ ADIS_GYRO_FIR_ENABLE
Definition: iio_adis_internals.h:145
@ ADIS_TEMP
Definition: iio_adis_internals.h:59
@ ADIS_FIR_BANK_SEL_YA
Definition: iio_adis_internals.h:157
#define ADIS_ACCEL_CHAN(mod, idx, adis_nb, attr)
Definition: iio_adis_internals.h:248
int adis_read_sync_selection(struct adis_dev *adis, uint32_t *sync_selection)
Read sync selection encoded value.
Definition: adis.c:2663
int adis_write_fir_en_za(struct adis_dev *adis, uint32_t fir_en_za)
Write z axis accelerometer filter enable bit value.
Definition: adis.c:2201
int adis_read_za_bias(struct adis_dev *adis, int32_t *za_bias)
Read raw acceleration offset correction on z axis.
Definition: adis.c:1676
@ ADIS_CMD_WRITE_LOCK
Definition: iio_adis_internals.h:178
int adis_read_diag_snsr_init_failure(struct adis_dev *adis, uint32_t *snsr_init_failure)
Diagnosis: read sensor initialization failure flag value.
Definition: adis.c:651
int adis_write_dec_rate(struct adis_dev *adis, uint32_t dec_rate)
Write decimation rate value.
Definition: adis.c:3379
int adis_read_serial_num(struct adis_dev *adis, uint32_t *serial_num)
Read serial number value.
Definition: adis.c:3802
@ ADIS_USR_SCR_4
Definition: iio_adis_internals.h:190
@ ADIS_FIR_EN_XA
Definition: iio_adis_internals.h:150
void adis1646x_iio_remove(struct adis_iio_dev *desc)
Remove adis1646x iio device.
Definition: iio_adis1646x.c:393
int adis_read_up_scale(struct adis_dev *adis, uint32_t *up_scale)
Read external clock scale factor value.
Definition: adis.c:3327
int adis_read_fir_en_xg(struct adis_dev *adis, uint32_t *fir_en_xg)
Read x axis gyroscope filter enable bit value.
Definition: adis.c:2069
@ ADIS_ACCEL_Y
Definition: iio_adis_internals.h:57
int adis_iio_read_debug_attrs(void *dev, char *buf, uint32_t len, const struct iio_ch_info *channel, intptr_t priv)
Handles the read request for debug attributes.
Definition: iio_adis.c:877
int adis_iio_read_gyro_meas_range(struct adis_iio_dev *iio_adis, char *buf)
Reads gyroscope measurement range value and returns it in char format.
Definition: iio_adis.c:863
int adis_cmd_write_lock(struct adis_dev *adis)
Command: write lock.
Definition: adis.c:3704
int adis_read_zg_bias(struct adis_dev *adis, int32_t *zg_bias)
Read raw gyroscope offset correction on z axis.
Definition: adis.c:1610
int adis_write_usr_scr_2(struct adis_dev *adis, uint32_t usr_scr_2)
Write user scratch register 2 value.
Definition: adis.c:3857
int adis_read_gpio_dir(struct adis_dev *adis, uint8_t dio_nb, uint32_t *dir)
Read gpio configured direction.
Definition: adis.c:2908
@ ADIS_DIO_2_LVL
Definition: iio_adis_internals.h:135
int iio_buffer_push_scan(struct iio_buffer *buffer, void *data)
Definition: iio.c:1434
@ IIO_DELTA_VELOCITY
Definition: iio_types.h:80
int adis_read_fir_bank_sel_zg(struct adis_dev *adis, uint32_t *fir_bank_sel_zg)
Read z axis gyroscope filter bank selection encoded value.
Definition: adis.c:2281
#define NO_OS_DIV_ROUND_CLOSEST(x, y)
Definition: no_os_util.h:54
int adis_read_diag_clk_err(struct adis_dev *adis, uint32_t *clk_err)
Diagnosis: read clock error flag value.
Definition: adis.c:795
int adis_read_firm_rev(struct adis_dev *adis, uint32_t *firm_rev)
Read firmware revision value.
Definition: adis.c:3736
int adis_read_bias_corr_en_za(struct adis_dev *adis, uint32_t *bias_corr_en_za)
Read z axis accelerometer bias correction enable bit value.
Definition: adis.c:3559
@ ADIS_GYRO_MEAS_RANGE
Definition: iio_adis_internals.h:119
@ ADIS_CMD_BIAS_CORR_UPDATE
Definition: iio_adis_internals.h:171
@ ADIS_TEMP_CHAN
Definition: adis.h:117
int adis_write_linear_accl_comp(struct adis_dev *adis, uint32_t linear_accl_comp)
Write linear acceleration compensation enable bit value.
Definition: adis.c:3162