Unified enabling of EXTI for gyro on F7 with other targets (#5364)

This commit is contained in:
Andrey Mironov 2018-03-04 01:49:36 +03:00 committed by Michael Keller
parent f73ada0687
commit 8319c6c6d1
1 changed files with 1 additions and 2 deletions

View File

@ -140,14 +140,13 @@ static void mpuIntExtiInit(gyroDev_t *gyro)
EXTIHandlerInit(&gyro->exti, mpuIntExtiHandler);
EXTIConfig(mpuIntIO, &gyro->exti, NVIC_PRIO_MPU_INT_EXTI, IO_CONFIG(GPIO_MODE_INPUT,0,GPIO_NOPULL)); // TODO - maybe pullup / pulldown ?
#else
IOInit(mpuIntIO, OWNER_MPU_EXTI, 0);
IOConfigGPIO(mpuIntIO, IOCFG_IN_FLOATING); // TODO - maybe pullup / pulldown ?
EXTIHandlerInit(&gyro->exti, mpuIntExtiHandler);
EXTIConfig(mpuIntIO, &gyro->exti, NVIC_PRIO_MPU_INT_EXTI, EXTI_Trigger_Rising);
EXTIEnable(mpuIntIO, true);
#endif
EXTIEnable(mpuIntIO, true);
}
#endif // MPU_INT_EXTI