Skip to content

Commit 1b2e4f0

Browse files
authored
Merge branch 'master' into test/add-cli-tests
2 parents a113bd1 + 0870f0e commit 1b2e4f0

2 files changed

Lines changed: 310 additions & 0 deletions

File tree

.github/workflows/rolling-semi-binary-build-win.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ on:
1414
- '**.py'
1515
- '**.yaml'
1616
- '.github/workflows/rolling-semi-binary-build-win.yml'
17+
- 'ros2_control.rolling.repos'
1718
- '**/package.xml'
1819
- '**/CMakeLists.txt'
1920
push: *event
@@ -29,3 +30,4 @@ jobs:
2930
with:
3031
ros_distro: rolling
3132
pixi_dependencies: typeguard jinja2 boost compilers cpp-expected
33+
upstream_workspace: ros2_control.rolling.repos
Lines changed: 308 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,308 @@
1+
// Copyright (c) 2021, b»robotized group
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
15+
#ifndef ROS2_CONTROL_TEST_ASSETS__TEST_ASSET_6D_ROBOT_DESCRIPTION_HPP_
16+
#define ROS2_CONTROL_TEST_ASSETS__TEST_ASSET_6D_ROBOT_DESCRIPTION_HPP_
17+
18+
namespace ros2_control_test_assets
19+
{
20+
const auto valid_6d_robot_urdf =
21+
R"(
22+
<?xml version="1.0" ?>
23+
<!-- =================================================================================== -->
24+
<!-- | This document was autogenerated by xacro from ./kr6.urdf.xacro | -->
25+
<!-- | EDITING THIS FILE BY HAND IS NOT RECOMMENDED | -->
26+
<!-- =================================================================================== -->
27+
<robot name="kuka_kr6">
28+
<!-- colours based on RAL values given in "FAQ - Colours of robot and robot
29+
controller", version "KUKA.Tifs | 2010-01-21 |YM| DefaultColorsRobotAndController.doc",
30+
downloaded 2015-07-18 from
31+
http://www.kuka.be/main/cservice/faqs/hardware/DefaultColorsRobotAndController.pdf
32+
33+
all RAL colours converted using http://www.visual-graphics.de/en/customer-care/ral-colours
34+
-->
35+
<link name="base_link">
36+
<visual>
37+
<origin rpy="0 0 0" xyz="0 0 0"/>
38+
<geometry>
39+
<mesh filename="package://ros2_control_test_assets/meshes/visual/base_link.dae"/>
40+
</geometry>
41+
<material name="">
42+
<color rgba="0.5058823529411764 0.47058823529411764 0.38823529411764707 1.0"/>
43+
</material>
44+
</visual>
45+
<collision>
46+
<origin rpy="0 0 0" xyz="0 0 0"/>
47+
<geometry>
48+
<mesh filename="package://ros2_control_test_assets/meshes/collision/base_link.stl"/>
49+
</geometry>
50+
</collision>
51+
</link>
52+
<link name="link_1">
53+
<visual>
54+
<origin rpy="0 0 0" xyz="0 0 0"/>
55+
<geometry>
56+
<mesh filename="package://ros2_control_test_assets/meshes/visual/link_1.dae"/>
57+
</geometry>
58+
<material name="">
59+
<color rgba="0.9647058823529412 0.47058823529411764 0.1568627450980392 1.0"/>
60+
</material>
61+
</visual>
62+
<collision>
63+
<origin rpy="0 0 0" xyz="0 0 0"/>
64+
<geometry>
65+
<mesh filename="package://ros2_control_test_assets/meshes/collision/link_1.stl"/>
66+
</geometry>
67+
</collision>
68+
</link>
69+
<link name="link_2">
70+
<visual>
71+
<origin rpy="0 0 0" xyz="0 0 0"/>
72+
<geometry>
73+
<mesh filename="package://ros2_control_test_assets/meshes/visual/link_2.dae"/>
74+
</geometry>
75+
<material name="">
76+
<color rgba="0.9647058823529412 0.47058823529411764 0.1568627450980392 1.0"/>
77+
</material>
78+
</visual>
79+
<collision>
80+
<origin rpy="0 0 0" xyz="0 0 0"/>
81+
<geometry>
82+
<mesh filename="package://ros2_control_test_assets/meshes/collision/link_2.stl"/>
83+
</geometry>
84+
</collision>
85+
</link>
86+
<link name="link_3">
87+
<visual>
88+
<origin rpy="0 0 0" xyz="0 0 0"/>
89+
<geometry>
90+
<mesh filename="package://ros2_control_test_assets/meshes/visual/link_3.dae"/>
91+
</geometry>
92+
<material name="">
93+
<color rgba="0.9647058823529412 0.47058823529411764 0.1568627450980392 1.0"/>
94+
</material>
95+
</visual>
96+
<collision>
97+
<origin rpy="0 0 0" xyz="0 0 0"/>
98+
<geometry>
99+
<mesh filename="package://ros2_control_test_assets/meshes/collision/link_3.stl"/>
100+
</geometry>
101+
</collision>
102+
</link>
103+
<link name="link_4">
104+
<visual>
105+
<origin rpy="0 0 0" xyz="0 0 0"/>
106+
<geometry>
107+
<mesh filename="package://ros2_control_test_assets/meshes/visual/link_4.dae"/>
108+
</geometry>
109+
<material name="">
110+
<color rgba="0.9647058823529412 0.47058823529411764 0.1568627450980392 1.0"/>
111+
</material>
112+
</visual>
113+
<collision>
114+
<origin rpy="0 0 0" xyz="0 0 0"/>
115+
<geometry>
116+
<mesh filename="package://ros2_control_test_assets/meshes/collision/link_4.stl"/>
117+
</geometry>
118+
</collision>
119+
</link>
120+
<link name="link_5">
121+
<visual>
122+
<origin rpy="0 0 0" xyz="0 0 0"/>
123+
<geometry>
124+
<mesh filename="package://ros2_control_test_assets/meshes/visual/link_5.dae"/>
125+
</geometry>
126+
<material name="">
127+
<color rgba="0.9647058823529412 0.47058823529411764 0.1568627450980392 1.0"/>
128+
</material>
129+
</visual>
130+
<collision>
131+
<origin rpy="0 0 0" xyz="0 0 0"/>
132+
<geometry>
133+
<mesh filename="package://ros2_control_test_assets/meshes/collision/link_5.stl"/>
134+
</geometry>
135+
</collision>
136+
</link>
137+
<link name="link_6">
138+
<visual>
139+
<origin rpy="0 0 0" xyz="0 0 0"/>
140+
<geometry>
141+
<mesh filename="package://ros2_control_test_assets/meshes/visual/link_6.dae"/>
142+
</geometry>
143+
<material name="">
144+
<color rgba="0.5058823529411764 0.47058823529411764 0.38823529411764707 1.0"/>
145+
</material>
146+
</visual>
147+
<collision>
148+
<origin rpy="0 0 0" xyz="0 0 0"/>
149+
<geometry>
150+
<mesh filename="package://ros2_control_test_assets/meshes/collision/link_6.stl"/>
151+
</geometry>
152+
</collision>
153+
</link>
154+
<!-- This frame corresponds to the $FLANGE coordinate system in KUKA KRC controllers. -->
155+
<link name="tool0"/>
156+
<joint name="joint_a1" type="revolute">
157+
<origin rpy="0 0 0" xyz="0 0 0.400"/>
158+
<parent link="base_link"/>
159+
<child link="link_1"/>
160+
<axis xyz="0 0 -1"/>
161+
<limit effort="0" lower="-2.9670597283903604" upper="2.9670597283903604" velocity="6.283185307179586"/>
162+
</joint>
163+
<joint name="joint_a2" type="revolute">
164+
<origin rpy="0 0 0" xyz="0.025 0 0"/>
165+
<parent link="link_1"/>
166+
<child link="link_2"/>
167+
<axis xyz="0 1 0"/>
168+
<limit effort="0" lower="-3.3161255787892263" upper="0.7853981633974483" velocity="5.235987755982989"/>
169+
</joint>
170+
<joint name="joint_a3" type="revolute">
171+
<origin rpy="0 0 0" xyz="0.455 0 0"/>
172+
<parent link="link_2"/>
173+
<child link="link_3"/>
174+
<axis xyz="0 1 0"/>
175+
<limit effort="0" lower="-2.0943951023931953" upper="2.722713633111154" velocity="6.283185307179586"/>
176+
</joint>
177+
<joint name="joint_a4" type="revolute">
178+
<origin rpy="0 0 0" xyz="0 0 0.035"/>
179+
<parent link="link_3"/>
180+
<child link="link_4"/>
181+
<axis xyz="-1 0 0"/>
182+
<limit effort="0" lower="-3.2288591161895095" upper="3.2288591161895095" velocity="6.649704450098396"/>
183+
</joint>
184+
<joint name="joint_a5" type="revolute">
185+
<origin rpy="0 0 0" xyz="0.420 0 0"/>
186+
<parent link="link_4"/>
187+
<child link="link_5"/>
188+
<axis xyz="0 1 0"/>
189+
<limit effort="0" lower="-2.0943951023931953" upper="2.0943951023931953" velocity="6.771877497737998"/>
190+
</joint>
191+
<joint name="joint_a6" type="revolute">
192+
<origin rpy="0 0 0" xyz="0.080 0 0"/>
193+
<parent link="link_5"/>
194+
<child link="link_6"/>
195+
<axis xyz="-1 0 0"/>
196+
<limit effort="0" lower="-6.1086523819801535" upper="6.1086523819801535" velocity="10.733774899765127"/>
197+
</joint>
198+
<joint name="joint_a6-tool0" type="fixed">
199+
<parent link="link_6"/>
200+
<child link="tool0"/>
201+
<origin rpy="0 1.5707963267948966 0" xyz="0 0 0"/>
202+
</joint>
203+
<!-- ROS base_link to KUKA $ROBROOT coordinate system transform -->
204+
<link name="base"/>
205+
<joint name="base_link-base" type="fixed">
206+
<origin rpy="0 0 0" xyz="0 0 0"/>
207+
<parent link="base_link"/>
208+
<child link="base"/>
209+
</joint>
210+
<ros2_control name="RobotSystem6DOF" type="system">
211+
<hardware>
212+
<plugin>mock_components/GenericSystem</plugin>
213+
</hardware>
214+
<joint name="joint_a1">
215+
<command_interface name="position">
216+
<param name="min">-1</param>
217+
<param name="max">1</param>
218+
</command_interface>
219+
<state_interface name="position"/>
220+
</joint>
221+
<joint name="joint_a2">
222+
<command_interface name="position">
223+
<param name="min">-1</param>
224+
<param name="max">1</param>
225+
</command_interface>
226+
<state_interface name="position"/>
227+
</joint>
228+
<joint name="joint_a3">
229+
<command_interface name="position">
230+
<param name="min">-1</param>
231+
<param name="max">1</param>
232+
</command_interface>
233+
<state_interface name="position"/>
234+
</joint>
235+
<joint name="joint_a4">
236+
<command_interface name="position">
237+
<param name="min">-1</param>
238+
<param name="max">1</param>
239+
</command_interface>
240+
<state_interface name="position"/>
241+
</joint>
242+
<joint name="joint_a5">
243+
<command_interface name="position">
244+
<param name="min">-1</param>
245+
<param name="max">1</param>
246+
</command_interface>
247+
<state_interface name="position"/>
248+
</joint>
249+
<joint name="joint_a6">
250+
<command_interface name="position">
251+
<param name="min">-1</param>
252+
<param name="max">1</param>
253+
</command_interface>
254+
<state_interface name="position"/>
255+
</joint>
256+
</ros2_control>
257+
</robot>
258+
)";
259+
260+
const auto valid_6d_robot_srdf =
261+
R"(
262+
<?xml version="1.0" ?>
263+
<robot name="kuka_kr6">
264+
<!--GROUPS: Representation of a set of joints and links. This can be useful for specifying DOF to plan for, defining arms, end effectors, etc-->
265+
<!--LINKS: When a link is specified, the parent joint of that link (if it exists) is automatically included-->
266+
<!--JOINTS: When a joint is specified, the child link of that joint (which will always exist) is automatically included-->
267+
<!--CHAINS: When a chain is specified, all the links along the chain (including endpoints) are included in the group. Additionally, all the joints that are parents to included links are also included. This means that joints along the chain and the parent joint of the base link are included in the group-->
268+
<!--SUBGROUPS: Groups can also be formed by referencing to already defined group names-->
269+
<group name="arm">
270+
<chain base_link="base_link" tip_link="tool0" />
271+
</group>
272+
<!--GROUP STATES: Purpose: Define a named state for a particular group, in terms of joint values. This is useful to define states like 'folded arms'-->
273+
<group_state name="home" group="arm">
274+
<joint name="joint_a1" value="0" />
275+
<joint name="joint_a2" value="-1.5708" />
276+
<joint name="joint_a3" value="1.5708" />
277+
<joint name="joint_a4" value="0" />
278+
<joint name="joint_a5" value="1.5708" />
279+
<joint name="joint_a6" value="0" />
280+
</group_state>
281+
<group_state name="zero" group="arm">
282+
<joint name="joint_a1" value="0" />
283+
<joint name="joint_a2" value="0" />
284+
<joint name="joint_a3" value="0" />
285+
<joint name="joint_a4" value="0" />
286+
<joint name="joint_a5" value="0" />
287+
<joint name="joint_a6" value="0" />
288+
</group_state>
289+
<!--DISABLE COLLISIONS: By default it is assumed that any link of the robot could potentially come into collision with any other link in the robot. This tag disables collision checking between a specified pair of links. -->
290+
<disable_collisions link1="base_link" link2="link_1" reason="Adjacent" />
291+
<disable_collisions link1="link_1" link2="link_2" reason="Adjacent" />
292+
<disable_collisions link1="link_2" link2="link_3" reason="Adjacent" />
293+
<disable_collisions link1="link_2" link2="link_4" reason="Never" />
294+
<disable_collisions link1="link_2" link2="link_5" reason="Never" />
295+
<disable_collisions link1="link_2" link2="link_6" reason="Never" />
296+
<disable_collisions link1="link_3" link2="link_4" reason="Adjacent" />
297+
<disable_collisions link1="link_3" link2="link_5" reason="Never" />
298+
<disable_collisions link1="link_3" link2="link_6" reason="Never" />
299+
<disable_collisions link1="link_4" link2="link_5" reason="Adjacent" />
300+
<disable_collisions link1="link_4" link2="link_6" reason="Never" />
301+
<disable_collisions link1="link_5" link2="link_6" reason="Adjacent" />
302+
</robot>
303+
304+
)";
305+
306+
} // namespace ros2_control_test_assets
307+
308+
#endif // ROS2_CONTROL_TEST_ASSETS__TEST_ASSET_6D_ROBOT_DESCRIPTION_HPP_

0 commit comments

Comments
 (0)