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

How to connect to a real universal robot (ur3)

asked 2018-11-15 03:16:33 -0500

Tim_ros_user gravatar image

updated 2018-11-15 07:15:10 -0500

Hi,

i try to connect ROS from a virtual box (ubuntu 16.04 + kinetic) with a real universal robot (ur3.5.1). I used the modern_driver and the moveit config from universal_robot package. I am able to ping to the robot and the actual position is shown up in the RVIZ interface (even if you move the robot), BUT if i try to plan and execute a trajectory it 'fails' and the robot doesen't move. Also the test_move.py don't work (the connection is build successfully but the robot don't move). On the teach penal of the robot i don't set any special config (just unlock the joints and enable networking) Do you have any idea? Maybe it is because of the virtual box?

Thank you!

Driver:

>`tim@ROS-PC:~$ roslaunch ur_modern_driver ur3_bringup.launch robot_ip:=192.168.0.3
... logging to /home/tim/.ros/log/b96c09dc-e8d5-11e8-b0b0-080027b2a5ed/roslaunch-ROS-PC-2278.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://localhost:46087/

SUMMARY
========

PARAMETERS
 * /robot_description: <?xml version="1....
 * /rosdistro: kinetic
 * /rosversion: 1.12.13
 * /ur_driver/base_frame: base
 * /ur_driver/max_joint_difference: 0.01
 * /ur_driver/max_payload: 3.0
 * /ur_driver/max_velocity: 10.0
 * /ur_driver/max_waiting_time: 2.0
 * /ur_driver/min_payload: 0.0
 * /ur_driver/prefix: 
 * /ur_driver/require_activation: Never
 * /ur_driver/robot_ip_address: 192.168.0.3
 * /ur_driver/servoj_gain: 100.0
 * /ur_driver/servoj_lookahead_time: 1.0
 * /ur_driver/servoj_time: 0.008
 * /ur_driver/servoj_time_waiting: 0.001
 * /ur_driver/shutdown_on_disconnect: True
 * /ur_driver/time_interval: 0.008
 * /ur_driver/tool_frame: tool0_controller
 * /ur_driver/use_lowbandwidth_trajectory_follower: False
 * /ur_driver/use_ros_control: False

NODES
  /
    robot_state_publisher (robot_state_publisher/robot_state_publisher)
    ur_driver (ur_modern_driver/ur_driver)

auto-starting new master
process[master]: started with pid [2292]
ROS_MASTER_URI=http://localhost:11311

setting /run_id to b96c09dc-e8d5-11e8-b0b0-080027b2a5ed
process[rosout-1]: started with pid [2305]
started core service [/rosout]
process[robot_state_publisher-2]: started with pid [2308]
process[ur_driver-3]: started with pid [2323]
[ INFO] [1542286530.435668630]: Setting up connection: 192.168.0.3:30003
[ INFO] [1542286530.450635527]: Connection established for 192.168.0.3:30003
[ INFO] [1542286530.450806340]: Setting up connection: 192.168.0.3:30001
[ INFO] [1542286530.452408980]: Connection established for 192.168.0.3:30001
[ INFO] [1542286530.458575005]: Got VersionMessage:
[ INFO] [1542286530.458634085]: project name: URControl
[ INFO] [1542286530.458665122]: version: 3.5.1
[ INFO] [1542286530.458695556]: build date: 12-12-2017, 11:25:40
[ INFO] [1542286530.458728250]: Disconnecting from 192.168.0.3:30001
[ INFO] [1542286530.492961865]: ActionServer enabled
[ INFO] [1542286530.493071996]: Use standard trajectory follower
[ INFO] [1542286530.497557112]: Setting up connection: :50001
[ INFO] [1542286530.497790485]: Connection established for :50001
[ INFO] [1542286530.497987392]: Initializing ur_driver/URScript subscriber
[ INFO] [1542286530.504972677]: The ur_driver/URScript initialized
[ INFO] [1542286530.505075917]: Notifier: Pipeline disconnect will shutdown the node
[ INFO] [1542286530.513697572]: Service 'ur_driver/robot_enable' activation mode: Never
[ INFO] [1542286530.513775597]: Starting main loop
[ INFO] [1542286530.514182378]: Starting pipeline RTPacket
[ INFO] [1542286530.514507689]: Setting up connection: 192.168.0.3:30003
[ INFO] [1542286530.514639898]: Setting up connection: 192.168.0.3:30002
[ INFO] [1542286530.514699348]: Starting pipeline StatePacket
[ INFO] [1542286530.516334795]: Connection established for 192.168.0.3:30003
[ INFO] [1542286530.517365609]: Starting ActionServer ...
(more)
edit retag flag offensive close merge delete

Comments

Can you show us the full error message when you try and execute a trajectory. Just saying it fails doesn't give us much to go on.

PeteBlackerThe3rd gravatar image PeteBlackerThe3rd  ( 2018-11-15 04:15:29 -0500 )edit

I have the same problem I don't get errors just a few warnings

ricktiggelaar gravatar image ricktiggelaar  ( 2018-11-15 05:00:47 -0500 )edit

i don't get errors, too. The robot just does not move...

Tim_ros_user gravatar image Tim_ros_user  ( 2018-11-15 06:45:37 -0500 )edit

If you try and plan and execute a trajectory in MoveIt it will always show some useful information in the terminal if it works or if it doesn't work. Can you show us the whole output of the terminal from when you run roslaunch.

PeteBlackerThe3rd gravatar image PeteBlackerThe3rd  ( 2018-11-15 06:49:16 -0500 )edit

i added some code

Tim_ros_user gravatar image Tim_ros_user  ( 2018-11-15 07:15:57 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-11-15 06:00:32 -0500

gvdhoorn gravatar image

The driver must be able to create a reverse connection from the robot to your ROS node.

If that connection doesn't succeed, the driver won't work.

If you're using a VM, they typically use NAT for the network interface, which doesn't let any traffic from the robot through to your ROS node(s).

edit flag offensive delete link more

Comments

Thanks for your answer! Yes, i use NAT in the virtual machine. But i am able to ping the robot and the robot is shown up in RVIZ. So there is some kind of connection... Do you think it is possible to control the robot with a virtual machine?

Tim_ros_user gravatar image Tim_ros_user  ( 2018-11-15 06:40:26 -0500 )edit

Try to switch to a bridged interface for the VM. If that solves the issue of not moving NAT could have been the problem. But I'm not sure of this, it's just something to check.

The reverse conx is only used when commanding motion, so initialisation could appear to be successful, but motion is not.

gvdhoorn gravatar image gvdhoorn  ( 2018-11-15 08:50:09 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2018-11-15 03:16:33 -0500

Seen: 945 times

Last updated: Nov 15 '18