mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-03 06:28:27 -04:00
ArduPlane: add AP_GRIPPER_ENABLED
This commit is contained in:
parent
be93d8212c
commit
9e0894c93a
@ -127,7 +127,7 @@ const AP_Scheduler::Task Plane::scheduler_tasks[] = {
|
||||
#if STATS_ENABLED == ENABLED
|
||||
SCHED_TASK_CLASS(AP_Stats, &plane.g2.stats, update, 1, 100, 153),
|
||||
#endif
|
||||
#if GRIPPER_ENABLED == ENABLED
|
||||
#if AP_GRIPPER_ENABLED
|
||||
SCHED_TASK_CLASS(AP_Gripper, &plane.g2.gripper, update, 10, 75, 156),
|
||||
#endif
|
||||
#if LANDING_GEAR_ENABLED == ENABLED
|
||||
|
@ -1070,7 +1070,7 @@ const AP_Param::GroupInfo ParametersG2::var_info[] = {
|
||||
// @User: Advanced
|
||||
AP_GROUPINFO("HOME_RESET_ALT", 11, ParametersG2, home_reset_threshold, 0),
|
||||
|
||||
#if GRIPPER_ENABLED == ENABLED
|
||||
#if AP_GRIPPER_ENABLED
|
||||
// @Group: GRIP_
|
||||
// @Path: ../libraries/AP_Gripper/AP_Gripper.cpp
|
||||
AP_SUBGROUPINFO(gripper, "GRIP_", 12, ParametersG2, AP_Gripper),
|
||||
|
@ -1,6 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include <AP_Common/AP_Common.h>
|
||||
#include <AP_Gripper/AP_Gripper.h>
|
||||
|
||||
// Global parameter class.
|
||||
//
|
||||
@ -513,7 +514,7 @@ public:
|
||||
// home reset altitude threshold
|
||||
AP_Int8 home_reset_threshold;
|
||||
|
||||
#if GRIPPER_ENABLED == ENABLED
|
||||
#if AP_GRIPPER_ENABLED
|
||||
// Payload Gripper
|
||||
AP_Gripper gripper;
|
||||
#endif
|
||||
|
@ -80,7 +80,6 @@
|
||||
#include <AP_Parachute/AP_Parachute.h>
|
||||
#include <AP_ADSB/AP_ADSB.h>
|
||||
#include <AP_ICEngine/AP_ICEngine.h>
|
||||
#include <AP_Gripper/AP_Gripper.h>
|
||||
#include <AP_Landing/AP_Landing.h>
|
||||
#include <AP_LandingGear/AP_LandingGear.h> // Landing Gear library
|
||||
#include <AP_Follow/AP_Follow.h>
|
||||
|
@ -238,12 +238,6 @@
|
||||
#define PARACHUTE HAL_PARACHUTE_ENABLED
|
||||
#endif
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
// Payload Gripper
|
||||
#ifndef GRIPPER_ENABLED
|
||||
#define GRIPPER_ENABLED !HAL_MINIMIZE_FEATURES
|
||||
#endif
|
||||
|
||||
#ifndef STATS_ENABLED
|
||||
# define STATS_ENABLED ENABLED
|
||||
#endif
|
||||
|
@ -146,7 +146,7 @@ void Plane::init_ardupilot()
|
||||
#endif
|
||||
|
||||
// init cargo gripper
|
||||
#if GRIPPER_ENABLED == ENABLED
|
||||
#if AP_GRIPPER_ENABLED
|
||||
g2.gripper.init();
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user