@@ -23,8 +23,8 @@ This URDF is very similar to the one we have already assembled. We simply need t
23
23
24
24
.. literalinclude :: ../my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro
25
25
:language: xml
26
- :start-at: <xacro:include filename="$(find ur_robot_driver )/urdf/ur.ros2_control.xacro"/>
27
- :end-at: <xacro:include filename="$(find ur_robot_driver )/urdf/ur.ros2_control.xacro"/>
26
+ :start-at: <xacro:include filename="$(find ur_description )/urdf/ur.ros2_control.xacro"/>
27
+ :end-at: <xacro:include filename="$(find ur_description )/urdf/ur.ros2_control.xacro"/>
28
28
:caption: my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro
29
29
30
30
@@ -33,7 +33,7 @@ define the necessary arguments that need to be passed to the macro,
33
33
.. literalinclude :: ../my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro
34
34
:language: xml
35
35
:start-at: <xacro:arg name="robot_ip" default="0.0.0.0"/>
36
- :end-at: <xacro:arg name="mock_sensor_commands " default="false" />
36
+ :end-at: <xacro:arg name="fake_sensor_commands " default="false" />
37
37
:caption: my_robot_cell_control/urdf/my_robot_cell_controlled.urdf.xacro
38
38
39
39
@@ -57,39 +57,12 @@ For now, we just copy the default one for the ur20.
57
57
cp $(ros2 pkg prefix ur_description)/share/ur_description/config/ur20/default_kinematics.yaml \
58
58
my_robot_cell_control/config/my_robot_calibration.yaml
59
59
60
-
61
- Create robot_state_publisher launchfile
62
- ---------------------------------------
63
-
64
- To use the custom controlled description, we need to generate a launchfile loading that description
65
- (Since it contains less / potentially different) arguments than the "default" one. In that
66
- launchfile we need to start a ``robot_state_publisher `` (RSP) node that will get the description as a
67
- parameter and redistribute it via the ``robot_description `` topic:
68
-
69
- .. literalinclude :: ../my_robot_cell_control/launch/rsp.launch.py
70
- :language: py
71
- :start-after: # Author: Felix Exner
72
- :linenos:
73
- :caption: my_robot_cell_control/launch/rsp.launch.py
74
-
75
- With this we could start our workcell using
76
-
77
- .. code-block :: bash
78
-
79
- ros2 launch ur_robot_driver ur_control.launch.py \
80
- description_launchfile:=$( ros2 pkg prefix my_robot_cell_control) /share/my_robot_cell_control/launch/rsp.launch.py \
81
- use_mock_hardware:=true \
82
- robot_ip:=123 \
83
- ur_type:=ur20 \
84
- rviz_config_file:=$( ros2 pkg prefix my_robot_cell_description) /share/my_robot_cell_description/rviz/urdf.rviz \
85
- tf_prefix:=ur20_
86
-
87
60
Create start_robot launchfile
88
61
-----------------------------
89
62
90
- Since the command above is obviously not very convenient to start our robot , we wrap that into another
91
- launchfile that includes the ``ur_control.launch.py `` launchfile with the correct description
92
- launchfile and prefix:
63
+ To launch a controlled robot with our custom description , we need to generate a launchfile. We
64
+ include the ``ur_control.launch.py `` file from the driver and set its parameters to match our
65
+ custom workcell.
93
66
94
67
.. literalinclude :: ../my_robot_cell_control/launch/start_robot.launch.py
95
68
:language: py
@@ -100,7 +73,7 @@ With that we can start the robot using
100
73
101
74
.. code-block :: bash
102
75
103
- ros2 launch my_robot_cell_control start_robot.launch.py use_mock_hardware :=true
76
+ ros2 launch my_robot_cell_control start_robot.launch.py use_fake_hardware :=true
104
77
105
78
Testing everything
106
79
------------------
@@ -121,7 +94,7 @@ We can start the system in a mocked simulation
121
94
.. code-block :: bash
122
95
123
96
# start the driver with mocked hardware
124
- ros2 launch my_robot_cell_control start_robot.launch.py use_mock_hardware :=true
97
+ ros2 launch my_robot_cell_control start_robot.launch.py use_fake_hardware :=true
125
98
126
99
Or to use it with a real robot:
127
100
0 commit comments