Skip to content

Commit b9487f2

Browse files
Shota AokiTiryoh
andauthored
Merge master branch (ROS1) into ros2 branch (#37)
* Add lidar link rename option (#23) * Add GitHub repository description to README (#27) * Fix slipping (#28) * Update model and add RT Corporation logo (#29) * Update tread (#31) * Add a simple launch file to load robot description (#34) * Support for launching multiple robots (#35) Co-authored-by: Daisuke Sato <daisuke.sato@rt-net.jp>
1 parent 34cce17 commit b9487f2

21 files changed

+735
-8975
lines changed

README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,14 @@ ROS package with URDF description macro for [Raspberry Pi Mouse](https://rt-net.
77
This ROS package was separated from [rt-net/raspimouse_sim](https://github.com/rt-net/raspimouse_sim).
88
See details from [rt-net/raspimouse_sim#42](https://github.com/rt-net/raspimouse_sim/pull/42).
99

10-
## Requirements
10+
The main development branch for ROS 1 is [`master`](https://github.com/rt-net/raspimouse_description/tree/master).
11+
The main development branch for ROS 2 is [`ros2`](https://github.com/rt-net/raspimouse_description/tree/ros2).
1112

12-
- ROS 2
13-
- [Foxy Fitzroy](https://docs.ros.org/en/foxy/index.html)
13+
## Supported ROS distributions
14+
15+
- ~~Kinetic ([`kinetic-devel`](https://github.com/rt-net/raspimouse_description/tree/kinetic-devel))~~ deprecated
16+
- Melodic ([`melodic-devel`](https://github.com/rt-net/raspimouse_description/tree/melodic-devel))
17+
- Foxy ([`foxy-devel`](https://github.com/rt-net/raspimouse_description/tree/foxy-devel))
1418

1519
## Installation
1620

launch/display.launch.py

Lines changed: 29 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@
1717
from ament_index_python.packages import get_package_share_directory
1818
from launch import LaunchDescription
1919
from launch.actions import DeclareLaunchArgument
20+
from launch.conditions import IfCondition
2021
from launch_ros.actions import Node
22+
from launch_ros.actions import PushRosNamespace
2123
from launch.substitutions import Command
2224
from launch.substitutions import LaunchConfiguration
2325

@@ -27,33 +29,57 @@ def generate_launch_description():
2729
'lidar',
2830
default_value='none',
2931
description='Set "none" or "urg".')
32+
declare_arg_lidar_frame = DeclareLaunchArgument(
33+
'lidar_frame',
34+
default_value='laser',
35+
description='Set lidar link name.')
36+
declare_arg_namespace = DeclareLaunchArgument(
37+
'namespace',
38+
default_value='',
39+
description='Set namespace for tf tree.')
40+
declare_arg_use_rviz = DeclareLaunchArgument(
41+
'use_rviz',
42+
default_value='true',
43+
description='Set "true" to launch rviz.')
3044

3145
xacro_file = os.path.join(
3246
get_package_share_directory('raspimouse_description'),
3347
'urdf',
3448
'raspimouse.urdf.xacro')
35-
params = {'robot_description': Command(['xacro ', xacro_file, ' lidar:=', LaunchConfiguration('lidar')])}
49+
params = {'robot_description': Command(['xacro ', xacro_file,
50+
' lidar:=', LaunchConfiguration('lidar'),
51+
' lidar_frame:=', LaunchConfiguration('lidar_frame'),
52+
]),
53+
'frame_prefix': [LaunchConfiguration('namespace'), '/']}
54+
55+
push_ns = PushRosNamespace([LaunchConfiguration('namespace')])
3656

3757
rsp = Node(package='robot_state_publisher',
3858
executable='robot_state_publisher',
3959
output='both',
4060
parameters=[params])
61+
4162
jsp = Node(
4263
package='joint_state_publisher_gui',
4364
executable='joint_state_publisher_gui',
4465
output='screen',
45-
)
66+
condition=IfCondition(LaunchConfiguration('use_rviz')))
4667

4768
rviz_config_file = get_package_share_directory(
4869
'raspimouse_description') + '/launch/config/urdf.rviz'
4970
rviz_node = Node(package='rviz2',
5071
executable='rviz2',
5172
name='rviz2',
5273
output='log',
53-
arguments=['-d', rviz_config_file])
74+
arguments=['-d', rviz_config_file],
75+
condition=IfCondition(LaunchConfiguration('use_rviz')))
5476

5577
return LaunchDescription([
5678
declare_arg_lidar,
79+
declare_arg_lidar_frame,
80+
declare_arg_namespace,
81+
declare_arg_use_rviz,
82+
push_ns,
5783
rsp,
5884
jsp,
5985
rviz_node,

meshes/dae/body/RasPiMouse_TopPlate.dae

Lines changed: 0 additions & 294 deletions
This file was deleted.

0 commit comments

Comments
 (0)