diff --git a/flight/targets/naze32/fw/pios_board.c b/flight/targets/naze32/fw/pios_board.c index e0227b9ada..03ec2595af 100644 --- a/flight/targets/naze32/fw/pios_board.c +++ b/flight/targets/naze32/fw/pios_board.c @@ -243,6 +243,11 @@ void PIOS_Board_Init(void) { pios_mpu_dev_t mpu_dev = NULL; int retval = PIOS_MPU_I2C_Init(&mpu_dev, pios_i2c_internal_id, &pios_mpu_cfg); + if (retval == -PIOS_MPU_ERROR_NOIRQ && mpu_pin == HWNAZE_MPU6050INTPIN_AUTO) { + // retry with alternate exti config, needed on afromini + pios_mpu_cfg.exti_cfg = (pios_mpu_cfg.exti_cfg == &pios_exti_mpu_cfg_v5) ? &pios_exti_mpu_cfg : &pios_exti_mpu_cfg_v5; + retval = PIOS_MPU_I2C_Init(&mpu_dev, pios_i2c_internal_id, &pios_mpu_cfg); + } if (retval != 0) PIOS_HAL_Panic(PIOS_LED_ALARM, PIOS_HAL_PANIC_IMU);