update
This commit is contained in:
@@ -99,6 +99,10 @@ bool DockPlannerConfig::load(const robot::NodeHandle& nh, DockPlannerConfig& con
|
||||
loaded.minimum_forward_distance, error) ||
|
||||
!readOptionalDouble(nh, "maneuver/maximum_forward_extension",
|
||||
loaded.maximum_forward_extension, error) ||
|
||||
!readOptionalDouble(nh, "terminal/straight_length",
|
||||
loaded.straight_length, error) ||
|
||||
!readOptionalDouble(nh, "maneuver/direct_entry_min_curve_room",
|
||||
loaded.direct_entry_min_curve_room, error) ||
|
||||
!readOptionalDouble(nh, "sampling/path_point_spacing",
|
||||
loaded.path_point_spacing, error))
|
||||
{
|
||||
@@ -130,8 +134,10 @@ bool DockPlannerConfig::validate(std::string& error) const
|
||||
{"kinematics/max_steering_angle", max_steering_angle},
|
||||
{"kinematics/wheel_base", wheel_base},
|
||||
{"terminal/reverse_distance_padding", reverse_distance_padding},
|
||||
{"terminal/straight_length", straight_length},
|
||||
{"maneuver/minimum_forward_distance", minimum_forward_distance},
|
||||
{"maneuver/maximum_forward_extension", maximum_forward_extension},
|
||||
{"maneuver/direct_entry_min_curve_room", direct_entry_min_curve_room},
|
||||
{"sampling/path_point_spacing", path_point_spacing},
|
||||
};
|
||||
|
||||
@@ -168,6 +174,17 @@ bool DockPlannerConfig::validate(std::string& error) const
|
||||
error = "parameter 'terminal/reverse_distance_padding' must be >= 0 m";
|
||||
return false;
|
||||
}
|
||||
if (straight_length < 0.0)
|
||||
{
|
||||
error = "parameter 'terminal/straight_length' must be >= 0 m";
|
||||
return false;
|
||||
}
|
||||
if (direct_entry_min_curve_room < 0.0)
|
||||
{
|
||||
error = "parameter 'maneuver/direct_entry_min_curve_room' must be >= 0 m "
|
||||
"(0 disables the direct entry)";
|
||||
return false;
|
||||
}
|
||||
if (minimum_forward_distance <= 0.0)
|
||||
{
|
||||
error = "parameter 'maneuver/minimum_forward_distance' must be > 0 m";
|
||||
|
||||
Reference in New Issue
Block a user