Function roboplan_ros_cpp::fromJointState

Function Documentation

tl::expected<roboplan::JointConfiguration, std::string> roboplan_ros_cpp::fromJointState(const sensor_msgs::msg::JointState &joint_state, const roboplan::Scene &scene, const JointStateConverterMap &joint_conversion_map)

Convert the provided ROS 2 JointState message to an equivalent roboplan::JointConfiguration.

Parameters:
  • joint_state – The ROS 2 JointState message to convert.

  • scene – The RoboPlan scene containing the model’s joint information.

  • joint_conversion_map – A mapping of joint names to their indexes in the model.

Returns:

An equivalent roboplan::JointConfiguration, or an error.