Class MotionGenerator
Defined in File motion_generator.hpp
Class Documentation
-
class MotionGenerator
An example showing how to generate a joint pose motion to a goal position. Adapted from: Wisama Khalil and Etienne Dombre. 2002. Modeling, Identification and Control of Robots (Kogan Page Science Paper edition).
Public Types
-
using Vector7d = Eigen::Matrix<double, 7, 1>
Public Functions
-
MotionGenerator(double speed_factor, const Vector7d &q_start, const Vector7d &q_goal)
Creates a new MotionGenerator instance for a target q.
- Parameters:
speed_factor – [in] General speed factor in range (0, 1].
q_start – [in] Start joint positions.
q_goal – [in] Target joint positions.
-
std::pair<Vector7d, bool> getDesiredJointPositions(const rclcpp::Duration &trajectory_time)
Sends joint position calculations
- Parameters:
robot_state – [in] Current state of the robot.
trajectory_time – [in] Amount of time, that has passed since the start of the trajectory.
- Returns:
Joint positions to use inside a control loop and a boolean indicating whether the motion is finished.
-
using Vector7d = Eigen::Matrix<double, 7, 1>