refactor(controller): Update TrajectoryFollow method signature and improve path handling

- Changed the signature of TrajectoryFollow to accept a vector of unitree::robot::go2::PathPoint instead of std::array<float, 6>.
- Updated the implementation of TrajectoryFollow in controller.cpp to utilize the new path type.
- Removed unnecessary status message in CMakeLists.txt related to unitree_sdk2 detection.
- Added a new function in custom_robot.cpp to create example trajectories for different path types (line, square, circle) and integrated it into the command processing for TrajectoryFollow.
This commit is contained in:
2025-09-23 18:40:42 +08:00
parent e0e1b5f642
commit 6c8a4a3b38
4 changed files with 99 additions and 6 deletions

View File

@@ -60,7 +60,7 @@ public:
bool FreeAvoid(bool flag);
bool WalkUpright(bool flag);
bool CrossStep(bool flag);
bool TrajectoryFollow(const std::vector<std::array<float, 6>>& path);
bool TrajectoryFollow(const std::vector<unitree::robot::go2::PathPoint>& path);
// Obstacle
bool SwitchSet(bool enable);