32 #ifndef JOINT_TRAJECTORY_STREAMER_H 33 #define JOINT_TRAJECTORY_STREAMER_H 35 #include <boost/thread/thread.hpp> 40 namespace joint_trajectory_streamer
47 namespace TransferStates
93 virtual bool init(
SmplMsgConnection* connection,
const std::vector<std::string> &joint_names,
94 const std::map<std::string, double> &velocity_limits = std::map<std::string, double>());
98 virtual void jointTrajectoryCB(
const trajectory_msgs::JointTrajectoryConstPtr &msg);
100 virtual bool trajectory_to_msgs(
const trajectory_msgs::JointTrajectoryConstPtr &traj, std::vector<JointTrajPtMessage>* msgs);
102 void streamingThread();
104 bool send_to_robot(
const std::vector<JointTrajPtMessage>& messages);
108 void trajectoryStop();
Message handler that relays joint trajectories to the robot controller.
ros::Time streaming_start_
virtual bool init(std::string default_ip="", int default_port=StandardSocketPorts::MOTION)
Initialize robot connection using default method.
JointTrajectoryStreamer(int min_buffer_size=1)
Default constructor.
std::vector< JointTrajPtMessage > current_traj_
boost::thread * streaming_thread_
Message handler that streams joint trajectories to the robot controller.