No Bhi360 anymotion data

Hi,

i am using 3 virtual sensors in BHI360 

rslt = bhy2_register_fifo_parse_callback(BHY2_SENSOR_ID_ANY_MOTION_LP, any_motion, (void*)&accuracy, dev);
rslt = bhy2_register_fifo_parse_callback(BHY2_SENSOR_ID_ACC_PASS, accelorometer, (void*)&accuracy, dev);
rslt = bhy2_register_fifo_parse_callback(BHY2_SENSOR_ID_GYRO_PASS, gyroscope, (void*)&accuracy, dev);

then i enable them

rslt = bhy2_set_virt_sensor_cfg(BHY2_SENSOR_ID_ANY_MOTION_LP,25.0,0, dev);
rslt = bhy2_set_virt_sensor_cfg(BHY2_SENSOR_ID_ACC_PASS,25.0,0, dev);
rslt = bhy2_set_virt_sensor_cfg(BHY2_SENSOR_ID_GYRO_PASS,25.0,0, dev);

i am getting accelorometer and gyroscope value but no anymotion data, i tried with 
BHY2_SENSOR_ID_ANY_MOTION_LP_WU insetad of BHY2_SENSOR_ID_ANY_MOTION_LP but nothing happen and i do not get any_motion callback called
Best reply by BSTRobin

Hi Ahmedba,

Please refer to attached example code.

anymotion.c
13.4KB
View original
1
3 replies
Resolved