ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Moveit arm show chessboard position Rviz [closed]

asked 2015-07-27 08:19:54 -0500

updated 2015-07-28 04:52:12 -0500

I have a 7DOF arm in moveit, which I can display in Rviz and also use for planning. I would like to include a frame to this Rviz model to show where a chessboard is located relative to the camera mounted on the robots gripper.

I have a node which can publish the TF of the detected chessboard, but I'm not sure how to merge with the moveit configuration.

I tired to use in the chess detection node the broadcaster like:

br.sendTransform(tf::StampedTransform(object_transform, ros::Time::now(), "camera_front", "calibration_grid"));

where camera_front is part of the robot configuration in moveit, and calibration_grid should show the position of the board relative to the camera front frame.

When I try it Rviz throws a warning:

[ WARN] [1438001098.758415265]: No transform available between frame 'calibration_grid' and planning frame '/base_footprint' (Could not find a connection between 'base_footprint' and 'calibration_grid' because they are not part of the same tree.Tf has two or more unconnected trees.)

Tthis is my moveit.rviz for the arm and the functional rviz setup for the camera solo camera.rviz.

Can anyone explain how can I represent the reference frame of the chessboard relative to the arm (camera front link on the arm)? Somehow I have to tell to Rviz that calibration_grid is part of the tree but it does not have to be included in the movement planning for the arm.

UPDATE 1: In RVIZ some parts of the robot arm are in warning when I load TF, in these links is camera_front. The warning is: camera_front No transform from [camera_front] to frame [base_footprint]. This camera_front is a link connected to the arm through fixed joints. It seams to be that every link in this chain has this warning massage in Rviz TF. So, this might be the problem. When I try to broadcast like

 br.sendTransform(tf::StampedTransform(object_transform, ros::Time::now(), "base_footprint", "calibration_grid"));

works well but the position of the chessboard is relative to the base of the arm and not the link where the camera is placed.

UPDAT 2:

Some detailes about the arm configuration before an observation: I connected to the last link of the arm (via fixed joints) a camera_back_of_box and to this a camera_front, all these joints (fixed) are also part of the arm group (created in moveit assistant). Now, if I change in Rviz the fixed frame to one of this links that hold the camera, than I can see the position of the chessboard, but the reference frames are shifted to the bottom of the robot in the origin of the world.

I think, this problem is due that I have multiple fixed joint is this robotic arm URDF model and if I understand well than the root of the tree should have fixed joint connection to the world. But what if there are more than one fixed joints, could this be the issue?

Update 3: The RobotState from moveit has the transform information of all link, just have ... (more)

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by zweistein
close date 2015-07-28 05:44:02.296560

Comments

This should be fairly straightforward. Are you publishing the transformation from calibration_grid to base_footprint?

Adam Allevato gravatar image Adam Allevato  ( 2015-07-27 08:41:55 -0500 )edit

I'm quit new with TF so I don't realy understand your question. camera_front is part of the robot arm which has the base foot print and in link camera_front is the real camera. That is why I try to broadcast like above.

zweistein gravatar image zweistein  ( 2015-07-27 09:01:37 -0500 )edit

I checked in Rviz and if I add TF than in the GUI I have an other warning related to some links to my arm: camera_front No transform from [camera_front] to frame [base_footprint]. But this code is automatically generated by moveit setup assistant.

zweistein gravatar image zweistein  ( 2015-07-27 09:07:55 -0500 )edit
1

All the TF frames can be published by any node. just add a static_transform_publisher node to publish the transformation you are looking for.

Adam Allevato gravatar image Adam Allevato  ( 2015-07-27 16:18:55 -0500 )edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2015-07-28 05:42:15 -0500

The solution was simple, in the launch file I have to start a node to publish the static_transform of the base_footprint, the joint_state, and the robot_state. It is important to publish the joint_state because it is needed by the robot_state. The launch file script looks like:

<node pkg="tf" type="static_transform_publisher" name="odom_broadcaster" args="0 0 0 0 0 0 odom_combined base_footprint 100" />
<node name="joint_state_publisher" pkg="joint_state_publisher" type="joint_state_publisher">
 <param name="/use_gui" value="false"/>
</node>
<node name="robot_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher" respawn="true" output="screen" />
<include file="$(find cyton_camera_moveit_conf)/launch/moveit_rviz.launch"/>
edit flag offensive delete link more
1

answered 2015-07-27 14:40:03 -0500

fapofa gravatar image

With number of well defined (static) transforms, you should be able to represent the base-robot-camera-grid transformation chain. For debugging purposes, you could check the TF debugging tools, such as view_frames or tf_monitor.

edit flag offensive delete link more

Comments

Do I have to redefine the static transformation model for the arm? Or can I use somehow the URDF model imported in MoveIt which does the hole planning for the arm? I was wondering if there could be a settings option to "turn on" the TF broadcast for some parts of the links from the URDF model.

zweistein gravatar image zweistein  ( 2015-07-27 15:12:48 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2015-07-27 08:19:54 -0500

Seen: 444 times

Last updated: Jul 28 '15