mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-03 06:28:27 -04:00
98f3f59fb6
* Prepare for external control enabled flag gating ability to arm in DDS Signed-off-by: Ryan Friedman <25047695+Ryanf55@users.noreply.github.com>
35 lines
640 B
C++
35 lines
640 B
C++
#include "AP_ExternalControl.h"
|
|
|
|
#if AP_EXTERNAL_CONTROL_ENABLED
|
|
|
|
// singleton instance
|
|
AP_ExternalControl *AP_ExternalControl::singleton;
|
|
|
|
bool AP_ExternalControl::arm(AP_Arming::Method method, bool do_arming_checks)
|
|
{
|
|
return AP::arming().arm(method, do_arming_checks);
|
|
}
|
|
|
|
bool AP_ExternalControl::disarm(AP_Arming::Method method, bool do_disarm_checks)
|
|
{
|
|
return AP::arming().disarm(method, do_disarm_checks);
|
|
}
|
|
|
|
AP_ExternalControl::AP_ExternalControl()
|
|
{
|
|
singleton = this;
|
|
}
|
|
|
|
|
|
namespace AP
|
|
{
|
|
|
|
AP_ExternalControl *externalcontrol()
|
|
{
|
|
return AP_ExternalControl::get_singleton();
|
|
}
|
|
|
|
};
|
|
|
|
#endif // AP_EXTERNAL_CONTROL_ENABLED
|