Commit Graph

12 Commits

Author SHA1 Message Date
07e2fd3b38 feat: per-marker dock_face_offset and pivot margin for dock_anchor mating_edge
The charger goal is the docked base_link pose, and the real charger face lies 0.40 m behind
it (detector offset_x). mating_edge measured the pivot sweep from a face assumed at
mating_extent (0.325 m) behind the goal, and still forced a terminal of at least
rear_extent. So the robot rotated with its centre about 0.725 m from the charger face.

Two optional keys, valid only with dock_anchor: mating_edge (rejected with center or face):
- dock_face_offset [m]: distance from the goal back to the real dock face. Default
  mating_extent.
- dock_pivot_safety_margin [m]: overrides maneuver/pivot_safety_margin for this marker.
A YAML null reads as unset, so move_base2 can clear a previous marker's value.

For mating_edge, the terminal floor becomes
max(mating_extent - face_offset, 0) + padding (floored at path_point_spacing), and the pivot
vertex becomes max(straight_distance, circumscribed - face_offset + margin). The costmap
rotation radius uses the same margin. center and face are unchanged.

KIT charger (face offset 0.40, margin 0.10, straight_length 0.2): vertex 0.2 m, robot centre
0.60 m from the charger face. Tests cover the three robot starts, the defaults, validation
and null handling. The test target now links yaml-cpp itself.
2026-10-29 16:54:16 +07:00
bac3ae0ba3 build: default the contract tests to the build mode instead of always on
The standalone CMake build is the robot deployment path and must not produce a
test executable; a catkin workspace is a development machine and keeps it.
Dropping include(CTest) also stops this package from defining BUILD_TESTING=ON
for the whole tree, which switched every other package's tests back on in the
aggregate standalone build.
2026-08-15 12:42:08 +07:00
2a16606c27 refactor & optimal 2026-08-14 14:04:47 +07:00
539fc5da16 Refactor DockPlanner: typed config, dock anchor, validated dock footprint
Split configuration out of the planner into DockPlannerConfig with explicit
load/validate, so a missing or malformed key fails at initialize() with a
message instead of silently defaulting to zero.

- initialize() now scopes its NodeHandle to the plugin name. The previous
  "~/<name>" form never resolved ("~" is not a key in the merged tree) and
  fell back to ROOT, so every parameter was read from the wrong place and
  cost_threshold silently dropped from 200 to 0.
- Replace robot_nav_2d_utils::footprintFromParams(), whose declaration and
  definition disagreed on the argument type. The symbol was never defined,
  and because the plugin is dlopen'd lazily the failure only surfaced at the
  call site on the robot, long after a clean build.
- Read footprint_dock, the dock object's polygon, with range and NaN checks.
  move_base2 copies it in per marker before the instance is built.
- dock_anchor selects whether the marker goal sits at the dock centre or on
  its approach face; the face case ignores footprint_dock entirely.
- makePlan() rejects start/goal outside the costmap global frame instead of
  planning across mismatched frames.
- Add dock_planner_test covering config validation, footprint parsing and
  path generation.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-12 21:52:52 +07:00
da82431cd9 update tf3 2026-02-07 10:56:15 +07:00
c4ae3961ab update for ROS 2026-01-07 16:54:50 +07:00
22aa83fe5a robot_nav_core 2026-01-07 09:17:55 +07:00
b5a1b7b6d8 Hiep update 2025-12-30 10:20:42 +07:00
9c84e64253 Hiep sua ten file 2025-12-30 09:59:48 +07:00
92264eaffc update 2025-12-30 09:11:02 +07:00
c5c55147b7 robot::console to robot_cpp 2025-12-24 14:29:24 +07:00
66be0d86cc first commit 2025-12-22 17:37:45 +07:00