ICM20948 DMP代码详解(106)
接前一篇文章:ICM20948 DMP代码详解(105)
上一回开始解析inv_set_hw_smplrt_dmp_odrs函数中的以下代码片段:
if (s->b2s_status != 0) {
unsigned short lB2SMinDly = min(INV_ODR_DEFAULT_B2S, minDly_accel);
lB2SMinDly = 1000/(get_multiple_56_rate(lB2SMinDly));
dmp_icm20948_set_b2s_rate(s, get_multiple_56_rate(lB2SMinDly));
minDly_accel = lB2SMinDly;
hw_smplrt_divider = SampleRateDividerGet(minDly_accel);
result |= DividerRateSet(s, lB2SMinDly, hw_smplrt_divider, INV_SENSOR_BRING_TO_SEE);
}
讲完了第2行代码。接下来是以下一行代码:
dmp_icm20948_set_b2s_