SMACC2
Loading...
Searching...
No Matches
Classes | Enumerations | Functions
cl_move_group_interface Namespace Reference

Classes

class  CbAttachObject
 
class  CbCircularPivotMotion
 
class  CbCircularPouringMotion
 
class  CbDetachObject
 
class  CbEndEffectorRotate
 
class  CbExecuteLastTrajectory
 
class  CbMoveCartesianRelative
 
class  CbMoveCartesianRelative2
 
class  CbMoveEndEffector
 
class  CbMoveEndEffectorRelative
 
class  CbMoveEndEffectorTrajectory
 
class  CbMoveJoints
 
class  CbMoveKnownState
 
class  CbMoveLastTrajectoryInitialState
 
class  CbMoveNamedTarget
 
class  CbUndoLastTrajectory
 
class  ClMoveGroup
 
class  CpGraspingComponent
 
class  CpTrajectoryHistory
 
struct  EvIncorrectInitialPosition
 
struct  EvJointDiscontinuity
 
struct  EvMoveGroupMotionExecutionFailed
 
struct  EvMoveGroupMotionExecutionSucceded
 
struct  TrajectoryHistoryEntry
 

Enumerations

enum class  ComputeJointTrajectoryErrorCode { SUCCESS , INCORRECT_INITIAL_STATE , JOINT_TRAJECTORY_DISCONTINUITY }
 

Functions

std::string currentJointStatesToString (moveit::planning_interface::MoveGroupInterface &moveGroupInterface, std::map< std::string, double > &targetJoints)
 
geometry_msgs::msg::Point & toMsg (const tf2::Vector3 &in, geometry_msgs::msg::Point &out)
 
void toMsg (const tf2::Transform &in, geometry_msgs::msg::Pose &out)
 
void fromMsg (const geometry_msgs::msg::Point &in, tf2::Vector3 &out)
 

Enumeration Type Documentation

◆ ComputeJointTrajectoryErrorCode

Function Documentation

◆ currentJointStatesToString()

std::string cl_move_group_interface::currentJointStatesToString ( moveit::planning_interface::MoveGroupInterface &  moveGroupInterface,
std::map< std::string, double > &  targetJoints 
)

Definition at line 49 of file cb_move_joints.cpp.

52{
53 auto state = moveGroupInterface.getCurrentState();
54
55 if (state == nullptr) return std::string();
56
57 auto vnames = state->getVariableNames();
58
59 std::stringstream ss;
60
61 for (auto & tgj : targetJoints)
62 {
63 auto it = std::find(vnames.begin(), vnames.end(), tgj.first);
64 auto index = std::distance(vnames.begin(), it);
65
66 ss << tgj.first << ":" << state->getVariablePosition(index) << std::endl;
67 }
68
69 return ss.str();
70}

Referenced by cl_move_group_interface::CbMoveJoints::moveJoints().

Here is the caller graph for this function:

◆ fromMsg()

void cl_move_group_interface::fromMsg ( const geometry_msgs::msg::Point &  in,
tf2::Vector3 &  out 
)

Definition at line 56 of file cb_pouring_motion.cpp.

57{
58 out = tf2::Vector3(in.x, in.y, in.z);
59}

Referenced by cl_move_group_interface::CbCircularPouringMotion::createMarkers(), and cl_move_group_interface::CbCircularPouringMotion::generateTrajectory().

Here is the caller graph for this function:

◆ toMsg() [1/2]

void cl_move_group_interface::toMsg ( const tf2::Transform &  in,
geometry_msgs::msg::Pose &  out 
)

Definition at line 48 of file cb_pouring_motion.cpp.

49{
50 out.position.x = in.getOrigin().getX();
51 out.position.y = in.getOrigin().getY();
52 out.position.z = in.getOrigin().getZ();
53 out.orientation = toMsg(in.getRotation());
54}
geometry_msgs::msg::Point & toMsg(const tf2::Vector3 &in, geometry_msgs::msg::Point &out)

References toMsg().

Here is the call graph for this function:

◆ toMsg() [2/2]

geometry_msgs::msg::Point & cl_move_group_interface::toMsg ( const tf2::Vector3 &  in,
geometry_msgs::msg::Point &  out 
)

Definition at line 40 of file cb_pouring_motion.cpp.

41{
42 out.x = in.getX();
43 out.y = in.getY();
44 out.z = in.getZ();
45 return out;
46}

Referenced by cl_move_group_interface::CbCircularPouringMotion::createMarkers(), and toMsg().

Here is the caller graph for this function: