1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-26 01:35:41 +03:00

Added checks for ESC_SENSOR feature being enabled when reading ESC sensor data. (#5663)

This commit is contained in:
Michael Keller 2018-04-11 23:31:14 +12:00 committed by GitHub
parent 6cfec6fc53
commit e0dcea4d48
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 21 additions and 5 deletions

View file

@ -276,6 +276,12 @@ static void validateAndFixConfig(void)
}
#endif // USE_OSD_SLAVE
#if defined(USE_ESC_SENSOR)
if (!findSerialPortConfig(FUNCTION_ESC_SENSOR)) {
featureClear(FEATURE_ESC_SENSOR);
}
#endif
// clear features that are not supported.
// I have kept them all here in one place, some could be moved to sections of code above.