ArduCopter: replace board ifdef with feature ifdef
This commit is contained in:
parent
c7fc3ffbc4
commit
cc7633f272
@ -189,9 +189,7 @@ bool AP_Arming_Copter::ins_checks(bool display_failure)
|
|||||||
|
|
||||||
bool AP_Arming_Copter::board_voltage_checks(bool display_failure)
|
bool AP_Arming_Copter::board_voltage_checks(bool display_failure)
|
||||||
{
|
{
|
||||||
#if CONFIG_HAL_BOARD != HAL_BOARD_VRBRAIN
|
#if HAL_HAVE_BOARD_VOLTAGE
|
||||||
#ifndef CONFIG_ARCH_BOARD_PX4FMU_V1
|
|
||||||
#ifndef CONFIG_ARCH_BOARD_AEROFC_V1
|
|
||||||
// check board voltage
|
// check board voltage
|
||||||
if ((checks_to_perform == ARMING_CHECK_ALL) || (checks_to_perform & ARMING_CHECK_VOLTAGE)) {
|
if ((checks_to_perform == ARMING_CHECK_ALL) || (checks_to_perform & ARMING_CHECK_VOLTAGE)) {
|
||||||
if (hal.analogin->board_voltage() < BOARD_VOLTAGE_MIN || hal.analogin->board_voltage() > BOARD_VOLTAGE_MAX) {
|
if (hal.analogin->board_voltage() < BOARD_VOLTAGE_MIN || hal.analogin->board_voltage() > BOARD_VOLTAGE_MAX) {
|
||||||
@ -201,9 +199,7 @@ bool AP_Arming_Copter::board_voltage_checks(bool display_failure)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
Parameters &g = copter.g;
|
Parameters &g = copter.g;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user