PX4 Firmware
PX4 Autopilot Software http://px4.io
BMI088_accel.hpp File Reference
Include dependency graph for BMI088_accel.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  BMI088_accel
 

Macros

#define BMI088_DEVICE_PATH_ACCEL   "/dev/bmi088_accel"
 
#define BMI088_DEVICE_PATH_ACCEL_EXT   "/dev/bmi088_accel_ext"
 
#define BMI088_ACC_CHIP_ID   0x00
 
#define BMI088_ACC_ERR_REG   0x02
 
#define BMI088_ACC_STATUS   0x03
 
#define BMI088_ACC_X_L   0x12
 
#define BMI088_ACC_X_H   0x13
 
#define BMI088_ACC_Y_L   0x14
 
#define BMI088_ACC_Y_H   0x15
 
#define BMI088_ACC_Z_L   0x16
 
#define BMI088_ACC_Z_H   0x17
 
#define BMI088_ACC_SENSORTIME_0   0x18
 
#define BMI088_ACC_SENSORTIME_1   0x19
 
#define BMI088_ACC_SENSORTIME_2   0x1A
 
#define BMI088_ACC_INT_STAT_1   0x1D
 
#define BMI088_ACC_TEMP_H   0x22
 
#define BMI088_ACC_TEMP_L   0x23
 
#define BMI088_ACC_CONF   0x40
 
#define BMI088_ACC_RANGE   0x41
 
#define BMI088_ACC_INT1_IO_CONF   0x53
 
#define BMI088_ACC_INT2_IO_CONF   0x54
 
#define BMI088_ACC_INT1_INT2_MAP_DATA   0x58
 
#define BMI088_ACC_SELF_TEST   0x6D
 
#define BMI088_ACC_PWR_CONF   0x7C
 
#define BMI088_ACC_PWR_CTRL   0x7D
 
#define BMI088_ACC_SOFTRESET   0x7E
 
#define BMI088_ACC_WHO_AM_I   0x1E
 
#define BMI088_ACC_ERR_REG_NO_ERROR   (0x00<<2)
 
#define BMI088_ACC_ERR_REG_ERROR   (0x01<<2)
 
#define BMI088_ACC_ERR_REG_FATAL_ERROR   (0x01<<0)
 
#define BMI088_ACC_STATUS_DRDY   (0x01<<7)
 
#define BMI088_ACC_INT_STAT_1_DRDY   (0x01<<7)
 
#define BMI088_ACC_CONF_BWP_4   (0x08<<4)
 
#define BMI088_ACC_CONF_BWP_2   (0x09<<4)
 
#define BMI088_ACC_CONF_BWP_NORMAL   (0x0A<<4)
 
#define BMI088_ACC_CONF_ODR_12_5   (0x05<<0)
 
#define BMI088_ACC_CONF_ODR_25   (0x06<<0)
 
#define BMI088_ACC_CONF_ODR_50   (0x07<<0)
 
#define BMI088_ACC_CONF_ODR_100   (0x08<<0)
 
#define BMI088_ACC_CONF_ODR_200   (0x09<<0)
 
#define BMI088_ACC_CONF_ODR_400   (0x0A<<0)
 
#define BMI088_ACC_CONF_ODR_800   (0x0B<<0)
 
#define BMI088_ACC_CONF_ODR_1600   (0x0C<<0)
 
#define BMI088_ACCEL_RANGE_3_G   (0x00<<0)
 
#define BMI088_ACCEL_RANGE_6_G   (0x01<<0)
 
#define BMI088_ACCEL_RANGE_12_G   (0x02<<0)
 
#define BMI088_ACCEL_RANGE_24_G   (0x03<<0)
 
#define BMI088_ACC_INT1_IO_CONF_INT1_IN   (0x01<<4)
 
#define BMI088_ACC_INT1_IO_CONF_INT1_OUT   (0x01<<3)
 
#define BMI088_ACC_INT1_IO_CONF_PP   (0x00<<2)
 
#define BMI088_ACC_INT1_IO_CONF_OD   (0x01<<2)
 
#define BMI088_ACC_INT1_IO_CONF_ACTIVE_LOW   (0x00<<1)
 
#define BMI088_ACC_INT1_IO_CONF_ACTIVE_HIGH   (0x01<<1)
 
#define BMI088_ACC_INT2_IO_CONF_INT1_IN   (0x01<<4)
 
#define BMI088_ACC_INT2_IO_CONF_INT1_OUT   (0x01<<3)
 
#define BMI088_ACC_INT2_IO_CONF_PP   (0x00<<2)
 
#define BMI088_ACC_INT2_IO_CONF_OD   (0x01<<2)
 
#define BMI088_ACC_INT2_IO_CONF_ACTIVE_LOW   (0x00<<1)
 
#define BMI088_ACC_INT2_IO_CONF_ACTIVE_HIGH   (0x01<<1)
 
#define BMI088_ACC_INT1_INT2_MAP_DATA_INT2_DRDY   (0x01<<6)
 
#define BMI088_ACC_INT1_INT2_MAP_DATA_INT1_DRDY   (0x01<<2)
 
#define BMI088_ACC_SELF_TEST_OFF   (0x00<<0)
 
#define BMI088_ACC_SELF_TEST_POSITIVE   (0x0D<<0)
 
#define BMI088_ACC_SELF_TEST_NEGATIVE   (0x09<<0)
 
#define BMI088_ACC_PWR_CONF_SUSPEND   (0x03<<0)
 
#define BMI088_ACC_PWR_CONF_ACTIVE   (0x00<<0)
 
#define BMI088_ACC_PWR_CTRL_EN   (0x04<<0)
 
#define BMI088_ACCEL_DEFAULT_RANGE_G   24
 
#define BMI088_ACCEL_DEFAULT_RATE   800
 
#define BMI088_ACCEL_MAX_RATE   800
 
#define BMI088_ACCEL_MAX_PUBLISH_RATE   800
 
#define BMI088_ACCEL_DEFAULT_DRIVER_FILTER_FREQ   50
 
#define BMI088_ACCEL_NUM_CHECKED_REGISTERS   7
 

Macro Definition Documentation

◆ BMI088_ACC_CHIP_ID

#define BMI088_ACC_CHIP_ID   0x00

Definition at line 45 of file BMI088_accel.hpp.

Referenced by BMI088_accel::probe(), and BMI088_accel::reset().

◆ BMI088_ACC_CONF

#define BMI088_ACC_CONF   0x40

Definition at line 61 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_CONF_BWP_2

#define BMI088_ACC_CONF_BWP_2   (0x09<<4)

Definition at line 88 of file BMI088_accel.hpp.

◆ BMI088_ACC_CONF_BWP_4

#define BMI088_ACC_CONF_BWP_4   (0x08<<4)

Definition at line 87 of file BMI088_accel.hpp.

◆ BMI088_ACC_CONF_BWP_NORMAL

#define BMI088_ACC_CONF_BWP_NORMAL   (0x0A<<4)

Definition at line 89 of file BMI088_accel.hpp.

◆ BMI088_ACC_CONF_ODR_100

#define BMI088_ACC_CONF_ODR_100   (0x08<<0)

Definition at line 94 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_CONF_ODR_12_5

#define BMI088_ACC_CONF_ODR_12_5   (0x05<<0)

Definition at line 91 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_CONF_ODR_1600

#define BMI088_ACC_CONF_ODR_1600   (0x0C<<0)

Definition at line 98 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_CONF_ODR_200

#define BMI088_ACC_CONF_ODR_200   (0x09<<0)

Definition at line 95 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_CONF_ODR_25

#define BMI088_ACC_CONF_ODR_25   (0x06<<0)

Definition at line 92 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_CONF_ODR_400

#define BMI088_ACC_CONF_ODR_400   (0x0A<<0)

Definition at line 96 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_CONF_ODR_50

#define BMI088_ACC_CONF_ODR_50   (0x07<<0)

Definition at line 93 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_CONF_ODR_800

#define BMI088_ACC_CONF_ODR_800   (0x0B<<0)

Definition at line 97 of file BMI088_accel.hpp.

Referenced by BMI088_accel::accel_set_sample_rate().

◆ BMI088_ACC_ERR_REG

#define BMI088_ACC_ERR_REG   0x02

Definition at line 47 of file BMI088_accel.hpp.

◆ BMI088_ACC_ERR_REG_ERROR

#define BMI088_ACC_ERR_REG_ERROR   (0x01<<2)

Definition at line 76 of file BMI088_accel.hpp.

◆ BMI088_ACC_ERR_REG_FATAL_ERROR

#define BMI088_ACC_ERR_REG_FATAL_ERROR   (0x01<<0)

Definition at line 78 of file BMI088_accel.hpp.

◆ BMI088_ACC_ERR_REG_NO_ERROR

#define BMI088_ACC_ERR_REG_NO_ERROR   (0x00<<2)

Definition at line 75 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT1_INT2_MAP_DATA

#define BMI088_ACC_INT1_INT2_MAP_DATA   0x58

Definition at line 65 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_INT1_INT2_MAP_DATA_INT1_DRDY

#define BMI088_ACC_INT1_INT2_MAP_DATA_INT1_DRDY   (0x01<<2)

Definition at line 130 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_INT1_INT2_MAP_DATA_INT2_DRDY

#define BMI088_ACC_INT1_INT2_MAP_DATA_INT2_DRDY   (0x01<<6)

Definition at line 129 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT1_IO_CONF

#define BMI088_ACC_INT1_IO_CONF   0x53

Definition at line 63 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_INT1_IO_CONF_ACTIVE_HIGH

#define BMI088_ACC_INT1_IO_CONF_ACTIVE_HIGH   (0x01<<1)

Definition at line 115 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_INT1_IO_CONF_ACTIVE_LOW

#define BMI088_ACC_INT1_IO_CONF_ACTIVE_LOW   (0x00<<1)

Definition at line 114 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT1_IO_CONF_INT1_IN

#define BMI088_ACC_INT1_IO_CONF_INT1_IN   (0x01<<4)

Definition at line 107 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT1_IO_CONF_INT1_OUT

#define BMI088_ACC_INT1_IO_CONF_INT1_OUT   (0x01<<3)

Definition at line 109 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_INT1_IO_CONF_OD

#define BMI088_ACC_INT1_IO_CONF_OD   (0x01<<2)

Definition at line 112 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT1_IO_CONF_PP

#define BMI088_ACC_INT1_IO_CONF_PP   (0x00<<2)

Definition at line 111 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_INT2_IO_CONF

#define BMI088_ACC_INT2_IO_CONF   0x54

Definition at line 64 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT2_IO_CONF_ACTIVE_HIGH

#define BMI088_ACC_INT2_IO_CONF_ACTIVE_HIGH   (0x01<<1)

Definition at line 126 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT2_IO_CONF_ACTIVE_LOW

#define BMI088_ACC_INT2_IO_CONF_ACTIVE_LOW   (0x00<<1)

Definition at line 125 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT2_IO_CONF_INT1_IN

#define BMI088_ACC_INT2_IO_CONF_INT1_IN   (0x01<<4)

Definition at line 118 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT2_IO_CONF_INT1_OUT

#define BMI088_ACC_INT2_IO_CONF_INT1_OUT   (0x01<<3)

Definition at line 120 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT2_IO_CONF_OD

#define BMI088_ACC_INT2_IO_CONF_OD   (0x01<<2)

Definition at line 123 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT2_IO_CONF_PP

#define BMI088_ACC_INT2_IO_CONF_PP   (0x00<<2)

Definition at line 122 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT_STAT_1

#define BMI088_ACC_INT_STAT_1   0x1D

Definition at line 58 of file BMI088_accel.hpp.

◆ BMI088_ACC_INT_STAT_1_DRDY

#define BMI088_ACC_INT_STAT_1_DRDY   (0x01<<7)

Definition at line 84 of file BMI088_accel.hpp.

◆ BMI088_ACC_PWR_CONF

#define BMI088_ACC_PWR_CONF   0x7C

Definition at line 67 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_PWR_CONF_ACTIVE

#define BMI088_ACC_PWR_CONF_ACTIVE   (0x00<<0)

Definition at line 139 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_PWR_CONF_SUSPEND

#define BMI088_ACC_PWR_CONF_SUSPEND   (0x03<<0)

Definition at line 138 of file BMI088_accel.hpp.

◆ BMI088_ACC_PWR_CTRL

#define BMI088_ACC_PWR_CTRL   0x7D

Definition at line 68 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_PWR_CTRL_EN

#define BMI088_ACC_PWR_CTRL_EN   (0x04<<0)

Definition at line 142 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACC_RANGE

#define BMI088_ACC_RANGE   0x41

Definition at line 62 of file BMI088_accel.hpp.

Referenced by BMI088_accel::set_accel_range().

◆ BMI088_ACC_SELF_TEST

#define BMI088_ACC_SELF_TEST   0x6D

Definition at line 66 of file BMI088_accel.hpp.

◆ BMI088_ACC_SELF_TEST_NEGATIVE

#define BMI088_ACC_SELF_TEST_NEGATIVE   (0x09<<0)

Definition at line 135 of file BMI088_accel.hpp.

◆ BMI088_ACC_SELF_TEST_OFF

#define BMI088_ACC_SELF_TEST_OFF   (0x00<<0)

Definition at line 133 of file BMI088_accel.hpp.

◆ BMI088_ACC_SELF_TEST_POSITIVE

#define BMI088_ACC_SELF_TEST_POSITIVE   (0x0D<<0)

Definition at line 134 of file BMI088_accel.hpp.

◆ BMI088_ACC_SENSORTIME_0

#define BMI088_ACC_SENSORTIME_0   0x18

Definition at line 55 of file BMI088_accel.hpp.

◆ BMI088_ACC_SENSORTIME_1

#define BMI088_ACC_SENSORTIME_1   0x19

Definition at line 56 of file BMI088_accel.hpp.

◆ BMI088_ACC_SENSORTIME_2

#define BMI088_ACC_SENSORTIME_2   0x1A

Definition at line 57 of file BMI088_accel.hpp.

◆ BMI088_ACC_SOFTRESET

#define BMI088_ACC_SOFTRESET   0x7E

◆ BMI088_ACC_STATUS

#define BMI088_ACC_STATUS   0x03

Definition at line 48 of file BMI088_accel.hpp.

Referenced by BMI088_accel::measure().

◆ BMI088_ACC_STATUS_DRDY

#define BMI088_ACC_STATUS_DRDY   (0x01<<7)

Definition at line 81 of file BMI088_accel.hpp.

Referenced by BMI088_accel::measure().

◆ BMI088_ACC_TEMP_H

#define BMI088_ACC_TEMP_H   0x22

Definition at line 59 of file BMI088_accel.hpp.

Referenced by BMI088_accel::measure().

◆ BMI088_ACC_TEMP_L

#define BMI088_ACC_TEMP_L   0x23

Definition at line 60 of file BMI088_accel.hpp.

◆ BMI088_ACC_WHO_AM_I

#define BMI088_ACC_WHO_AM_I   0x1E

Definition at line 72 of file BMI088_accel.hpp.

Referenced by BMI088_accel::probe().

◆ BMI088_ACC_X_H

#define BMI088_ACC_X_H   0x13

Definition at line 50 of file BMI088_accel.hpp.

◆ BMI088_ACC_X_L

#define BMI088_ACC_X_L   0x12

Definition at line 49 of file BMI088_accel.hpp.

Referenced by BMI088_accel::measure().

◆ BMI088_ACC_Y_H

#define BMI088_ACC_Y_H   0x15

Definition at line 52 of file BMI088_accel.hpp.

◆ BMI088_ACC_Y_L

#define BMI088_ACC_Y_L   0x14

Definition at line 51 of file BMI088_accel.hpp.

◆ BMI088_ACC_Z_H

#define BMI088_ACC_Z_H   0x17

Definition at line 54 of file BMI088_accel.hpp.

◆ BMI088_ACC_Z_L

#define BMI088_ACC_Z_L   0x16

Definition at line 53 of file BMI088_accel.hpp.

◆ BMI088_ACCEL_DEFAULT_DRIVER_FILTER_FREQ

#define BMI088_ACCEL_DEFAULT_DRIVER_FILTER_FREQ   50

Definition at line 155 of file BMI088_accel.hpp.

◆ BMI088_ACCEL_DEFAULT_RANGE_G

#define BMI088_ACCEL_DEFAULT_RANGE_G   24

Definition at line 150 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset().

◆ BMI088_ACCEL_DEFAULT_RATE

#define BMI088_ACCEL_DEFAULT_RATE   800

Definition at line 151 of file BMI088_accel.hpp.

Referenced by BMI088_accel::reset(), and BMI088_accel::start().

◆ BMI088_ACCEL_MAX_PUBLISH_RATE

#define BMI088_ACCEL_MAX_PUBLISH_RATE   800

Definition at line 153 of file BMI088_accel.hpp.

◆ BMI088_ACCEL_MAX_RATE

#define BMI088_ACCEL_MAX_RATE   800

Definition at line 152 of file BMI088_accel.hpp.

◆ BMI088_ACCEL_NUM_CHECKED_REGISTERS

#define BMI088_ACCEL_NUM_CHECKED_REGISTERS   7

◆ BMI088_ACCEL_RANGE_12_G

#define BMI088_ACCEL_RANGE_12_G   (0x02<<0)

Definition at line 103 of file BMI088_accel.hpp.

Referenced by BMI088_accel::set_accel_range().

◆ BMI088_ACCEL_RANGE_24_G

#define BMI088_ACCEL_RANGE_24_G   (0x03<<0)

Definition at line 104 of file BMI088_accel.hpp.

Referenced by BMI088_accel::set_accel_range().

◆ BMI088_ACCEL_RANGE_3_G

#define BMI088_ACCEL_RANGE_3_G   (0x00<<0)

Definition at line 101 of file BMI088_accel.hpp.

Referenced by BMI088_accel::set_accel_range().

◆ BMI088_ACCEL_RANGE_6_G

#define BMI088_ACCEL_RANGE_6_G   (0x01<<0)

Definition at line 102 of file BMI088_accel.hpp.

Referenced by BMI088_accel::set_accel_range().

◆ BMI088_DEVICE_PATH_ACCEL

#define BMI088_DEVICE_PATH_ACCEL   "/dev/bmi088_accel"

Definition at line 41 of file BMI088_accel.hpp.

Referenced by bmi088::start().

◆ BMI088_DEVICE_PATH_ACCEL_EXT

#define BMI088_DEVICE_PATH_ACCEL_EXT   "/dev/bmi088_accel_ext"

Definition at line 42 of file BMI088_accel.hpp.

Referenced by bmi088::start().