I'm having trouble getting freefall detection to work on an ICM-42670-P, so I have several questions --- mostly related to the information in AN-000271 https://invensense.tdk.com/wp-content/uploads/2023/05/an-000271-icm-42607x-icm-42670x-apex-motion-functions-description-and-usage.pdf
1) What ACCEL_ODR (ODR for the accelerometers) and DMP_ODR (ODR for the APEX features) values can I use? Table 1 in AN-000271 suggests that freefall detection needs both ODRs to be 400 Hz (DMP_ODR=1), and AN-000271 section 6.1 states "Freefall works at ODR of 400 Hz". However, the suggested freefall initialization procedure in AN-000271 section 6.2 says to set DMP_ODR to 0 (25 Hz) or 2 (50 Hz) and ACCEL_ODR to any value between 5 and 11, which includes values below 400 Hz. So, section 6.2 seems to contradict Table 1.
2) The suggested freefall initialization procedure in AN-000271 section 6.2 puts the accelerometer into low-power mode. Is this necessary, or can the accelerometer be used in low-noise mode?
3) The suggested freefall initialization procedure in AN-000271 section 6.2 sets various freefall configuration parameters in registers APEX_CONFIG5, APEX_CONFIG9, APEX_CONFIG10, APEX_CONFIG11, and APEX_CONFIG12. If the default values in those registers are satisfactory for my application, do I need to write to those registers?
4) Does the order of writing to registers APEX_CONFIG5, APEX_CONFIG9, APEX_CONFIG10, APEX_CONFIG11, and APEX_CONFIG12 matter?
5) What is the effect of DMP_POWER_SAVE_EN in the APEX_CONFIG0 register? The datasheet states "When this bit is set to 1, power saving is enabled for DMP algorithms". Does power saving disable or affect the function of freefall detection (or other APEX functions)?
Question 1 is the most important one to me. I'm guessing that I know the answers to 2-4, but I'd like to confirm.
I've attached screenshots that highlight various documents that I reference.
Thanks.
Hello,
1-) ACCEL_ODR between 5 and 11 is just the ODR selections available for APEX algorithms, I understand the confusion. You should set it to 400Hz for FreeFall. The ACCEL_ODR field must be configured to an ODR equal or greater to the DMP_ODR field, for correct device operation. Actually DMP_ODR should be set to 0x01 for 400Hz.
2-) Accelerometer LP mode uses Wake Up oscillator clock, it is a needed feature to use LP mode.
3-) If default is satisfactory, no need to write.
4-) As long as they are done before Enable algorithm execution, it should be fine
Following up on the second question I want to use the IMU to continuously read accelerometer and gyroscope values while also enabling Freefall and SMD (Significant Motion Detection) interrupts. However, the application note mentions that the power register needs to be set to 0x02 for Freefall and SMD detection, which puts the accelerometer on low power mode and turns off the gyroscope. Is there a way to enable Freefall and SMD detection without switching the power register, or is changing the power register the only option? If there's an alternative configuration or register setting, please advise.
1. During freefall testing, when the product is released from a certain height, only the low-g threshold is triggered, and freefall is not detected. Is there an alternative method or approach to test freefall detection more effectively?
2. According to the application note, the accelerometer operates in low-power mode, allowing its values to be used. However, what is the expected behavior or usage of the gyroscope values in this scenario? Should the gyroscope also be configured or considered in any other setting because if i change the power management the apex features not working. please advise on this also.