getCurrentPose("end_effector_link") returns the same numbers

750 views
Skip to first unread message

Chittaranjan S Swaminathan

unread,
Jul 1, 2014, 6:47:58 AM7/1/14
to moveit...@googlegroups.com
Hello, 

I have the following problem.

The functino getCurrentPose from "planning_interface::MoveGroup" seems to return the same set of numbers all the time. 

The tf tree looks fine. In fact it seems perfect.

The planning however succeeds and execution of motion also succeeds.

Are there any common causes that might cause this error?

rosrun tf tf_echo base_link jaco_gripper_tool_frame

returns the correct position of the arm.

--------------------------------------------------------------------------------------------------------
                                             DETAILS
--------------------------------------------------------------------------------------------------------
A brief outline of what I am doing is as follows:

I am using "fivef's" JacoROS --> the jaco_moveit_config from that package.

To have cleaner topics I did the following:

1. jaco_node runs with a namespace "jaco"

<node ns="jaco" name="jaco_node" pkg="jaco" type="jaco" args='$(find jaco)/../CSharpWrapper/CSharpWrapper/bin/Debug/CSharpWrapper.dll'  output="screen"/>

2. The robot_state_publisher is informed of this using a remap from joint_states to jaco/joint_states

<node name="jaco_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher">
    <remap from="joint_states" to="/jaco/joint_states"/>
</node>

3. In the move_group.launch, I have included a remap from joint_states to jaco/joint_states under the <node> tag for the move_group node.

4. In the controllers.yaml file, I have changed the names for the controllers from "whatever_controller" to "jaco/whatever_controller"

controller_manager_ns: moveit_simple_controller_manager
controller_list:
  - name: "jaco/jaco_arm_controller"
    action_ns: joint_trajectory_action
    type: FollowJointTrajectory
    default: true
    joints:
        - jaco_joint_1
        - jaco_joint_2
        - jaco_joint_3
        - jaco_joint_4
        - jaco_joint_5
        - jaco_joint_6

  - name: "jaco/jaco_gripper_controller"
    action_ns: gripper_command
    type: GripperCommand
    default: true
    joints:
        - jaco_finger_joint_1
        - jaco_finger_joint_2
        - jaco_finger_joint_3


If I remove all the namespaces and run all the stuff as such, planning_interface::MoveGroup::getCurrentPose() returns a proper value that agrees to the result from tf_echo.

But, in the current configuration described above, I see that getCurrentPose reports the value for the Zero pose (rviz shows the robot in the zero pose).

I thought initially that some part of the code is relying on joint_states topic, I hence checked "rostopic info joint_states" and it returns "unknown topic" as I expected.

I am sure it is a very silly error. Please help! :)

Thank you so much.

Chittaranjan S Srinivas


Jonathan Rovira

unread,
Jul 18, 2014, 5:10:20 PM7/18/14
to moveit...@googlegroups.com, ch...@live.in
Hi Chittaranjan,

Did you end up solving this problem? I am experiencing the same issue that you have described and have been unable to remedy it. I'd appreciate any updates you have.

Thanks,
Jon

Philippe Capdepuy

unread,
Jul 19, 2014, 2:47:58 AM7/19/14
to Jonathan Rovira, moveit-users, ch...@live.in
Hi,

This sounds indeed like a problem in topic name, e.g. the move_group is not receiving the correct joint_states values.
Try
  rostopic list | grep joint_states
And make sure you have only one such topic ( jaco/joint_states in your case), do a rostopic info on it to make sure movegroup has subscribed to it.
Also echo your joint_states to check if you have the proper values published.

--

Regards,

Dr. Philippe Capdepuy

Research Engineer

Génération Robots / HumaRobotics

Tel : +33 5 56 39 37 05

www.humarobotics.com

www.generationrobots.com

 

Découvrez Baxter, votre nouveau compagnon

pour la recherche et l’éducation

Baxter Research Robot

Baxter Research Robot

ksat...@gmail.com

unread,
Jul 19, 2014, 4:29:46 AM7/19/14
to moveit...@googlegroups.com, ch...@live.in
Hello!

Unfortunately, the problem persisted even after ensuring that (in my case) move_group was subscribed to jaco/joint_states and there was no evidence of any other joint_states topic. I checked this using both "rosnode info move_group" and "rostopic list | grep joint_states". 

However I found another solution to my problem. 

The robot we have has a ptu anyway and that will also have a joint_states topic. 

So I decided to do this:

<!-- state publisher -->
    <node ns="jaco" name="jaco_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher">
    </node>
    
<node name="joint_state_merger" pkg="joint_state_publisher" type="joint_state_publisher">
<rosparam command="load" file="$(find jaco)/source_list.yaml"/>
</node>

Where my source_list.yaml has:

source_list: ['jaco/joint_states', 'ptu/joint_states']

This means that I can retain the namespaces and also ensure that move_group has the correct values.

I hope this helps!

Chittaranjan

blake....@uconn.edu

unread,
Aug 6, 2014, 6:32:58 PM8/6/14
to moveit...@googlegroups.com, jonathanr...@u.northwestern.edu, ch...@live.in
Hello Phillippe,

I have a quick question for you, I tried 
   rostopic list | grep joint_states
and received
   /joint_states
   /robot/joint_states
   /robot/ref_joint_states

I am having the issue where get_current_pose is returning the same numbers every time. I echoed /robot/joint_states  to make sure they are correct, and they are. I tried  rostopic info on  /robot/joint_states and movegroup was one of the subscribers.

My question is, why are the same values constantly displayed if movegroup is subscribed to the right topic? Also, should there only be one joint_states topic, not 3??

Thank you,
Blake Apatow

Philippe Capdepuy

unread,
Aug 6, 2014, 6:45:47 PM8/6/14
to blake....@uconn.edu, moveit-users, Jonathan Rovira, ch...@live.in
Hi Blake,

The question is who is creating the /joint_states? It should not be there. Do a
  rostopic info /joint_states
to find the node. That should help you find your issue.
I think the ref topic is legitimate, are you on Baxter?

blake....@uconn.edu

unread,
Aug 7, 2014, 3:09:50 PM8/7/14
to moveit...@googlegroups.com, blake....@uconn.edu, jonathanr...@u.northwestern.edu, ch...@live.in
Thank you very much for the response. Yes I am using Baxter.

I set up three terminals
1st)  rosrun baxter_interface joint_trajectory_action_server.py
2nd)  roslaunch baxter_moveit_config demo_baxter.launch
3rd)  roslaunch baxter_moveit_generated move_group.launch

I then, in a fourth terminal, tried rostopic info/joint_states

There is no publisher and the sole subscriber to /joint_states was   /move_group (http://rclbaxter-ThinkCentre-M83.local:34313/).

But looking through move_group files I can't seem to find where /joint_states is subscribed to. Any tips? Or do I just need to keep digging?



Thanks,
Blake


Chittaranjan S Swaminathan

unread,
Aug 7, 2014, 3:12:38 PM8/7/14
to blake....@uconn.edu, moveit...@googlegroups.com, jonathanr...@u.northwestern.edu
Did you see my answer? Using joint_state_publisher, you could combine multiple sources and push them all together in /joint_states after which moveit will work properly.

blake....@uconn.edu

unread,
Aug 7, 2014, 3:45:12 PM8/7/14
to moveit...@googlegroups.com, blake....@uconn.edu, jonathanr...@u.northwestern.edu, ch...@live.in
Hello, yes I did see your answer. There is a joint_state_publisher in several files on my computer, which do you suggest I use? I'm assuming I should use the file 'move.group' that is in move_group launch folder, which I believe is the source of the error seeing as it is the only subscriber to /joint_states.

But what is the source_list.yaml ? I guess I just need a little more background for the procedure. 

Forgive my inexperience, I am on the beginning portion of my moveit/robotics journey.

Chittaranjan S Swaminathan

unread,
Aug 8, 2014, 2:11:56 AM8/8/14
to blake....@uconn.edu, moveit...@googlegroups.com, Jonathan Rovira
Say you have the 'baxter_bringup.launch' in a baxter_bringup directory.



<!-- state publisher -->
    <node ns="jaco" name="jaco_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher">
    </node>
This above line is the state publisher from the robot. In your case this should already be there. I leave it here to make things clear. This was generating the jaco/joint_states topic. The one below is what you need. Add these lines to your baxter_bringup.launch file (of what ever launch file you are running to run the baxter-ros drivers):
    
<node name="joint_state_merger" pkg="joint_state_publisher" type="joint_state_publisher">
<rosparam command="load" file="$(find baxter_bringup)/source_list.yaml"/>
</node>

Then create a file source_list.yaml in the baxter_bringup directory

Again, edit the list below to contain the different joint states topic that you have.

source_list: ['arm1/joint_states', 'ptu/joint_states']

blake....@uconn.edu

unread,
Aug 14, 2014, 3:25:29 PM8/14/14
to moveit...@googlegroups.com, blake....@uconn.edu, jonathanr...@u.northwestern.edu, ch...@live.in
Ok I have tried this, but it did not seem to change my joint states. They are still printing as the same numbers. I think my issue may be even more elementary. Do you mind if I quickly ask you, if my terminals are configured correctly.

1st terminal -  rosrun baxter_interface joint_trajectory_action_server.py  <-- joint trajectory controller
2nd -  roslaunch baxter_moveit_config demo_baxter.launch    <-- this is the demo_baxter.launch that pulls up rviz with the robot in the scene. This is not a demo created from the setup assistant, it is one I downloaded initially.
3rd - roslaunch baxter_moveit_generated move_group.launch  <-- this is the move_group that was created after I completed the set-up assistant

My question is, am i missing something fundamental? I don't want to waste anyone's time asking for answers to more advanced questions, when my issues may be more basic so to speak. Also, if you know of any thorough tutorial, I would appreciate being pointed in that direction. Many of the tutorials I have seen seem to lack description of the fundamentals. By the way I'm trying to use Moveit! on ROS with Baxter the robot.

Thank you,
Blake
Reply all
Reply to author
Forward
0 new messages