ros-industrial / motoman

ROS-Industrial Motoman support (http://wiki.ros.org/motoman)
145 stars 192 forks source link

Question of move_to_joint.py in Motoman_driver #294

Closed Gloriabhsfer closed 4 years ago

Gloriabhsfer commented 4 years ago

Hi all,

I am planning to set groups of waypoints for my Motoman GP8 robot (YRC1000 Mirco with smart pendant). And I just start look at the python file. In that python code, what you get is form a rosbag https://github.com/ros-industrial/motoman/blob/197d2f8da805c9849a821e8b627748811b3242a1/motoman_driver/src/move_to_joint.py#L80-L89 And I have read the rosbag tutorial about how to record a rosbag.http://wiki.ros.org/rosbag/Tutorials/Recording%20and%20playing%20back%20data But in this code, you set waypoint when you run the python script, and you didn't generate or save the joint in a rosbag file. Cause what I want to do is set a group of waypoint and let the robot following these points. In my understanding, I need to set the directory with where you set the rosbag and run the waypoint in rosbag step by step. But I am not sure it's right or not. Please correct me if my understanding is wrong.

Thanks, Gloria

gavanderhoorn commented 4 years ago

I would refer you to #229. That links to my work where I've a skeleton of an action server client that is probably what you are looking for.

The rosbag approach in moveit_to_joint is a nice idea, but may not be the most user friendly at this point.

I would also recommend you take a look at some motion planning frameworks, such as MoveIt, Descartes, MoveIt's MTC or even Tesseract/TrajOpt.

If you're only interested in hard-coding joint trajectory points, I would suggest generating an INFORM job and pushing that to the controller in some way. Using (Moto)ROS for hard-coded trajectories is not something I would think the most efficient.

It is possible though.

gavanderhoorn commented 4 years ago

As I've noted in https://github.com/ros-industrial/motoman/issues/229#issuecomment-402759642, that script was not tested too much, so you may run into some minor issues.

I see now that I've not actually (deep) cloned the trajectory pts, so no motion may result (or only a single motion, instead of three).

The approach shown would still be valid though.

Gloriabhsfer commented 4 years ago

Thanks for your reply, the code in #229 seems works. Yes, I agree we can use some motion planning framework and we are now using MoveIt. But the connection has some issue and it seems we didn't set the controller right. So we need to read more about how to set the MoveIt controller. Now we want first do a demo pick and place task so we want to hard coding it into a python file. I will close the issue and reply under it if we make any progress. Best, Gloria