Files
agv_pro_ros2/TODO.md
T

42 lines
2.7 KiB
Markdown

# TODO
Need to patch src/upstream/slam_gmapping/include/slam_gmapping/slam_gmapping.h
#include "tf2_geometry_msgs/tf2_geometry_msgs.h"
#include "tf2_geometry_msgs/tf2_geometry_msgs.hpp"
## CAN wheel control (agv_pro_can service / wheel_interface:=can)
Switched from an unverified CANopen approach (`agv_pro_canopen_config`/`ros2_canopen`,
now removed) to the RobStride private protocol via the community `robstride_ros2`
package, after empirically confirming real CAN communication with the wheel drives
(RobStride RS01 motors, CAN IDs 1-4, direction-confirmed via `candump -x`; see
`/memories/repo/agv_can_serial_hw_notes.md`). Remaining before this is production-ready:
- [x] Determine which physical wheel corner each CAN ID (1-4) actually drives — VERIFIED
by rotating each wheel in turn and watching `scripts/hw_debug/robstride_rotation_watch.py`:
1=front_left, 2=front_right, 3=rear_left, 4=rear_right (matches the xacro default).
- [x] Confirm per-wheel `direction` (sign) — all 4 wheels rotated the same physical
"forward" way; raw mechpos was negative for left-side motors (1,3) and positive for
right-side motors (2,4), consistent with mirrored motor mounting. Set `direction=-1`
for IDs 1/3 and `direction=1` for IDs 2/4 in the xacro. LIVE-VALIDATED by
`scripts/hw_debug/robstride_spin_test.py`: commanded all 4 motors forward at
2 rad/s for 4s using this sign convention and all 4 wheels visually spun forward
together (user-confirmed). Note: this validated the raw protocol-level sign
convention via a standalone script bypassing `ros2_control`; the `robstride_ros2`
driver's own `direction` xacro param still needs a real `ros2_control` build/test
to confirm it applies the same convention end-to-end.
- [ ] Determine real `gear_ratio` (currently 1.0 placeholder) from the drivetrain so
commanded/measured velocity is in correct SI units at the wheel.
- [ ] Tune `kp`/`kd` velocity-mode gains (currently placeholder `kp=0.0 kd=0.8`) for the
real mecanum drivetrain.
- [ ] Confirm `can_timeout_ticks` (currently the package default, 4000 ticks = 200 ms) is an
appropriate watchdog window for this platform.
- [ ] Build-test: `colcon build` will build `robstride_ros2` and `ros2_socketcan` from
source per `upstream.jazzy.repos` — not yet exercised in this workspace.
- [ ] End-to-end test: confirm `ros2 launch agv_pro_bringup agv_pro_bringup.launch.py
wheel_interface:=can` actually drives all four wheels through the full
`ros2_control`/`mecanum_drive_controller` stack (only ad-hoc Python/CAN scripts have
been validated against the hardware so far, not the ROS2 stack itself).