payload deliverer: remove PD_GRIPPER_EN as unnecessary, reduce gripper timeout to 1s

This commit is contained in:
Jacob Dahl
2025-07-28 11:25:17 -08:00
committed by Jacob Dahl
parent 8d4993e654
commit 463ddcab86
6 changed files with 7 additions and 23 deletions
+1 -8
View File
@@ -5,13 +5,6 @@ parameters:
definitions:
# Gripper configuration
PD_GRIPPER_EN:
description:
short: Enable Gripper actuation in Payload Deliverer
type: boolean
default: 0
reboot_required: true
PD_GRIPPER_TYPE:
description:
short: Type of Gripper (Servo, etc.)
@@ -34,4 +27,4 @@ parameters:
type: float
unit: s
min: 0
default: 3
default: 1
@@ -54,7 +54,7 @@ bool PayloadDeliverer::init()
void PayloadDeliverer::configure_gripper()
{
// If gripper instance is invalid, and user enabled the gripper, try initializing it
if (!_gripper.is_valid() && _param_gripper_enable.get()) {
if (!_gripper.is_valid()) {
GripperConfig config{};
config.type = (GripperConfig::GripperType)_param_gripper_type.get();
config.sensor = GripperConfig::GripperSensorType::NONE; // Feedback sensor isn't supported for now
@@ -104,7 +104,7 @@ private:
/**
* @brief Initialize or deinitialize gripper instance based on parameter settings
*
* Depending on `PD_GRIPPER_EN` and the state of `_gripper` instance, this function will
* Depending on the state of `_gripper` instance, this function will
* either try to initialize or de-initialize the gripper appropriately.
*/
void configure_gripper();
@@ -159,7 +159,6 @@ private:
DEFINE_PARAMETERS(
(ParamFloat<px4::params::PD_GRIPPER_TO>) _param_gripper_timeout_s,
(ParamInt<px4::params::PD_GRIPPER_TYPE>) _param_gripper_type,
(ParamBool<px4::params::PD_GRIPPER_EN>) _param_gripper_enable
(ParamInt<px4::params::PD_GRIPPER_TYPE>) _param_gripper_type
)
};