51 #ifndef BHY_UC_DRIVER_TYPES_H_
52 #define BHY_UC_DRIVER_TYPES_H_
60 #define BHY_PAGE_SYSTEM 1
61 #define BHY_PARAM_SYSTEM_META_EVENT_CTRL 1
62 #define BHY_PARAM_SYSTEM_FIFO_CTRL 2
63 #define BHY_PARAM_SYSTEM_STAUS_BANK_0 3
64 #define BHY_PARAM_SYSTEM_STAUS_BANK_1 4
65 #define BHY_PARAM_SYSTEM_STAUS_BANK_2 5
66 #define BHY_PARAM_SYSTEM_STAUS_BANK_3 6
67 #define BHY_PARAM_SYSTEM_CUSTOM_VERSION 24
68 #define BHY_PARAM_SYSTEM_WAKE_UP_META_EVENT_CTRL 29
69 #define BHY_PARAM_SYSTEM_HOST_IRQ_TIMESTAMP 30
70 #define BHY_PARAM_SYSTEM_PHYSICAL_SENSOR_STATUS 31
71 #define BHY_PARAM_SYSTEM_PHYSICAL_SENSOR_PRESENT 32
72 #define BHY_PARAM_SYSTEM_PHYSICAL_SENSOR_DETAIL_0 32
73 #define BHY_PARAM_SYSTEM_PHYSICAL_SENSOR_DETAIL_ACC 33
75 #define VS_NON_WAKEUP 0
77 #define VS_FLUSH_NONE 0x00
78 #define VS_FLUSH_ALL 0xFF
79 #define VS_FLUSH_SINGLE 0x01
81 #define META_EVENT_1_INT_ENABLE_BIT (1<<0)
82 #define META_EVENT_1_ENABLE_BIT (1<<1)
89 VS_TYPE_ACCELEROMETER = VS_ID_ACCELEROMETER,
90 VS_TYPE_GEOMAGNETIC_FIELD = VS_ID_MAGNETOMETER,
91 VS_TYPE_ORIENTATION = VS_ID_ORIENTATION,
92 VS_TYPE_GYROSCOPE = VS_ID_GYROSCOPE,
93 VS_TYPE_LIGHT = VS_ID_LIGHT,
94 VS_TYPE_PRESSURE = VS_ID_BAROMETER,
95 VS_TYPE_TEMPERATURE = VS_ID_TEMPERATURE,
96 VS_TYPE_PROXIMITY = VS_ID_PROXIMITY,
97 VS_TYPE_GRAVITY = VS_ID_GRAVITY,
98 VS_TYPE_LINEAR_ACCELERATION = VS_ID_LINEAR_ACCELERATION,
99 VS_TYPE_ROTATION_VECTOR = VS_ID_ROTATION_VECTOR,
100 VS_TYPE_RELATIVE_HUMIDITY = VS_ID_HUMIDITY,
101 VS_TYPE_AMBIENT_TEMPERATURE = VS_ID_AMBIENT_TEMPERATURE,
102 VS_TYPE_MAGNETIC_FIELD_UNCALIBRATED = VS_ID_UNCALIBRATED_MAGNETOMETER,
103 VS_TYPE_GAME_ROTATION_VECTOR = VS_ID_GAME_ROTATION_VECTOR,
104 VS_TYPE_GYROSCOPE_UNCALIBRATED = VS_ID_UNCALIBRATED_GYROSCOPE,
105 VS_TYPE_SIGNIFICANT_MOTION = VS_ID_SIGNIFICANT_MOTION,
106 VS_TYPE_STEP_DETECTOR = VS_ID_STEP_DETECTOR,
107 VS_TYPE_STEP_COUNTER = VS_ID_STEP_COUNTER,
108 VS_TYPE_GEOMAGNETIC_ROTATION_VECTOR = VS_ID_GEOMAGNETIC_ROTATION_VECTOR,
109 VS_TYPE_HEART_RATE = VS_ID_HEART_RATE,
110 VS_TYPE_TILT = VS_ID_TILT_DETECTOR,
111 VS_TYPE_WAKEUP = VS_ID_WAKE_GESTURE,
112 VS_TYPE_GLANCE = VS_ID_GLANCE_GESTURE,
113 VS_TYPE_PICKUP = VS_ID_PICKUP_GESTURE,
114 VS_TYPE_CUS1 = VS_ID_CUS1,
115 VS_TYPE_CUS2 = VS_ID_CUS2,
116 VS_TYPE_CUS3 = VS_ID_CUS3,
117 VS_TYPE_CUS4 = VS_ID_CUS4,
118 VS_TYPE_CUS5 = VS_ID_CUS5,
119 VS_TYPE_ACTIVITY_RECOGNITION = VS_ID_ACTIVITY
120 } bhy_virtual_sensor_t;
123 BHY_META_EVENT_TYPE_NOT_USED = 0,
124 BHY_META_EVENT_TYPE_FLUSH_COMPLETE = 1,
125 BHY_META_EVENT_TYPE_SAMPLE_RATE_CHANGED = 2,
126 BHY_META_EVENT_TYPE_POWER_MODE_CHANGED = 3,
127 BHY_META_EVENT_TYPE_ERROR = 4,
128 BHY_META_EVENT_TYPE_ALGORITHM = 5,
130 BHY_META_EVENT_TYPE_SENSOR_ERROR = 11,
131 BHY_META_EVENT_TYPE_FIFO_OVERFLOW = 12,
132 BHY_META_EVENT_TYPE_DYNAMIC_RANGE_CHANGED = 13,
133 BHY_META_EVENT_TYPE_FIFO_WATERMARK = 14,
134 BHY_META_EVENT_TYPE_SELF_TEST_RESULTS = 15,
135 BHY_META_EVENT_TYPE_INITIALIZED = 16,
137 } bhy_meta_event_type_t;
141 BHY_GP_REG_20 = 0x4B,
142 BHY_GP_REG_21 = 0x4C,
143 BHY_GP_REG_22 = 0x4D,
144 BHY_GP_REG_23 = 0x4E,
145 BHY_GP_REG_24 = 0x4F,
148 BHY_GP_REG_31 = 0x56,
149 BHY_GP_REG_32 = 0x57,
150 BHY_GP_REG_33 = 0x58,
151 BHY_GP_REG_34 = 0x59,
152 BHY_GP_REG_35 = 0x5A,
153 BHY_GP_REG_36 = 0x5B,
156 BHY_GP_REG_46 = 0x65,
157 BHY_GP_REG_47 = 0x66,
158 BHY_GP_REG_48 = 0x67,
159 BHY_GP_REG_49 = 0x68,
160 BHY_GP_REG_50 = 0x69,
161 BHY_GP_REG_51 = 0x6A,
162 BHY_GP_REG_52 = 0x6B,
164 } bhy_gp_register_type_t;
169 BHY_DATA_TYPE_PADDING = 0,
170 BHY_DATA_TYPE_QUATERNION = 1,
171 BHY_DATA_TYPE_VECTOR = 2,
172 BHY_DATA_TYPE_SCALAR_U8 = 3,
173 BHY_DATA_TYPE_SCALAR_U16 = 4,
174 BHY_DATA_TYPE_SCALAR_S16 = 5,
175 BHY_DATA_TYPE_SCALAR_U24 = 6,
176 BHY_DATA_TYPE_SENSOR_EVENT = 7,
177 BHY_DATA_TYPE_UNCALIB_VECTOR = 8,
178 BHY_DATA_TYPE_META_EVENT = 9,
179 BHY_DATA_TYPE_BSX = 10,
180 BHY_DATA_TYPE_DEBUG = 11,
181 BHY_DATA_TYPE_CUS1 = 12,
182 BHY_DATA_TYPE_CUS2 = 13,
183 BHY_DATA_TYPE_CUS3 = 14,
184 BHY_DATA_TYPE_CUS4 = 15,
185 BHY_DATA_TYPE_CUS5 = 16,
189 META_EVENT_IN_NON_WAKEUP_FIFO = 1,
190 META_EVENT_IN_WAKEUP_FIFO = 29,
191 } bhy_meta_event_fifo_type_t;
195 PHYSICAL_SENSOR_INDEX_ACC = 0,
196 PHYSICAL_SENSOR_INDEX_MAG,
197 PHYSICAL_SENSOR_INDEX_GYRO,
198 PHYSICAL_SENSOR_COUNT
199 } bhy_physical_sensor_index_type_t;
216 int16_t estimated_accuracy;
263 uint8_t meta_event_id;
264 bhy_meta_event_type_t event_number;
266 uint8_t event_specific;
287 int16_t confidencelevel;
header file of bhy_uc_driver.c
Definition: bhy_uc_driver_types.h:269
Definition: bhy_uc_driver_types.h:292
Definition: bhy_uc_driver_types.h:277
Definition: bhy_uc_driver_types.h:206
Definition: bhy_uc_driver_types.h:282
Definition: bhy_uc_driver_types.h:210
Definition: bhy_uc_driver_types.h:237
Definition: bhy_uc_driver_types.h:232
Definition: bhy_uc_driver_types.h:242
Definition: bhy_uc_driver_types.h:227
Definition: bhy_uc_driver_types.h:247
Definition: bhy_uc_driver_types.h:251
Definition: bhy_uc_driver_types.h:219
Definition: bhy_uc_driver_types.h:301