We are currently working on interrupt-based event detection using the BMI270 (Legacy firmware).
System Details:
MCU: Nordic NRF5340
Sensor: BMI270
Firmware used: bmi270_legacy
Code Reference what we used: https://github.com/boschsensortec/BMI270_SensorAPI/blob/master/bmi270_legacy_examples
We were able to successfully detect Free-Fall (Low-G) using polling mode (continuous monitoring at MCU side). However, for our application this approach is not suitable because the MCU needs to remain in sleep mode during idle state. Therefore, we require interrupt-based event detection to wake up the MCU on fall detection.
We configured the BMI270 for Low-G detection with interrupt mapping to INT1. The initialization sequence is as follows:
bmi270_legacy_init(&dev)
Accelerometer configuration (ODR = 100Hz, Range = 2G)
bmi2_sensor_enable({BMI2_ACCEL, BMI2_LOW_G})
bmi2_map_sens_int(BMI2_LOW_G, BMI2_INT1)
INT1 configured as:
Output enabled
Active high
Push-pull
Tested in both latch and non-latch mode
Note: PFA code for the complete reference.
However, no interrupt is generated on the INT1 pin when a fall event occurs
Additionally, while reviewing the API, we could not find bmi2_enable_features() in our driver package. We would like clarification on:
In legacy firmware, is Low-G/Tilt required to be enabled using bmi2_sensor_enable() or bmi2_enable_features()?
Is there any additional configuration required for enabling interrupt generation for Low-G or Tilt in legacy mode.