mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-05 07:28:29 -04:00
AP_Arming: make AP_RANGEFINDER_ENABLED remove more code
This commit is contained in:
parent
dabc34e7de
commit
955245e4b7
@ -916,6 +916,7 @@ bool AP_Arming::mission_checks(bool report)
|
|||||||
|
|
||||||
bool AP_Arming::rangefinder_checks(bool report)
|
bool AP_Arming::rangefinder_checks(bool report)
|
||||||
{
|
{
|
||||||
|
#if AP_RANGEFINDER_ENABLED
|
||||||
if (check_enabled(ARMING_CHECK_RANGEFINDER)) {
|
if (check_enabled(ARMING_CHECK_RANGEFINDER)) {
|
||||||
RangeFinder *range = RangeFinder::get_singleton();
|
RangeFinder *range = RangeFinder::get_singleton();
|
||||||
if (range == nullptr) {
|
if (range == nullptr) {
|
||||||
@ -928,6 +929,7 @@ bool AP_Arming::rangefinder_checks(bool report)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user