ICM20948 DMP代码详解(89)
接前一篇文章:ICM20948 DMP代码详解(88)
上一回完成了对inv_convert_androidSensor_to_control函数的解析。本回回到inv_enable_sensor_internal函数中,继续解析后续内容。为了便于理解和回顾,再次贴出inv_enable_sensor_internal函数源码,在EMD-Core\sources\Invn\Devices\Drivers\ICM20948\Icm20948DataBaseControl.c中,如下:
static int inv_enable_sensor_internal(struct inv_icm20948 * s, unsigned char androidSensor, unsigned char enable, char * mems_put_to_sleep)
{int result = 0;unsigned short inv_event_control = 0;unsigned short data_rdy_status = 0;unsigned long steps=0;const short inv_androidSensor_to_control_bits[ANDROID_S