Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change launch files to python #1

Open
wants to merge 1 commit into
base: humble
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 0 additions & 17 deletions launch/laserscan_multi_merger.launch

This file was deleted.

29 changes: 29 additions & 0 deletions launch/laserscan_multi_merger.launch.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
from launch import LaunchDescription
from launch_ros.actions import Node


def generate_launch_description():
laserscan_multi_merger = Node(
package='ira_laser_tools',
namespace='',
executable='laserscan_multi_merger',
name='laserscan_multi_merger',
output='screen',
parameters=[{
'destination_frame': 'base_link',
'cloud_destination_topic': '/merged_cloud',
'scan_destination_topic': '/scan_multi',
'laserscan_topics': '/scansx /scandx',
# LIST OF THE LASER SCAN TOPICS TO SUBSCRIBE
'angle_min': -3.14,
'angle_max': 3.14,
'angle_increment': 0.00437,
'scan_time': 0.0,
'range_min': 0.1,
'range_max': 2.0,
}],
)

description = LaunchDescription()
description.add_action(laserscan_multi_merger)
return description
34 changes: 0 additions & 34 deletions launch/laserscan_virtualizer.launch

This file was deleted.

48 changes: 48 additions & 0 deletions launch/laserscan_virtualizer.launch.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
from launch import LaunchDescription
from launch_ros.actions import Node


def generate_launch_description():
tf_node_1 = Node(
package="tf2_ros",
executable="static_transform_publisher",
name='ira_static_broadcaster1',
arguments=['0', '0', '0', '0.3', '0', '0', 'base_link', 'scansx'],
)

tf_node_2 = Node(
package="tf2_ros",
executable="static_transform_publisher",
name='ira_static_broadcaster2',
arguments=['0', '0', '0', '0', '0', '0', 'base_link', 'scandx'],
)

laserscan_virtualizer = Node(
package='ira_laser_tools',
namespace='',
executable='laserscan_virtualizer',
name='laserscan_virtualizer',
output='screen',
parameters=[{
# INPUT POINT CLOUD
"cloud_topic": "/trunk4_camera_depth_camera/points",
# REFERENCE FRAME WHICH LASER(s) ARE RELATED
"base_frame": "base_link",
# VIRTUAL LASER OUTPUT TOPIC, LEAVE VALUE EMPTY TO PUBLISH ON THE VIRTUAL LASER NAMES (param: output_laser_scan)
"output_laser_topic": "/scan",
# LIST OF THE VIRTUAL LASER SCANS. YOU MUST PROVIDE THE STATIC TRANSFORMS TO TF, SEE ABOVE
"virtual_laser_scan": "scansx scandx",
'angle_min': -3.14,
'angle_max': 3.14,
'angle_increment': 0.00437,
'scan_time': 0.0,
'range_min': 0.1,
'range_max': 2.0,
}],
)

description = LaunchDescription()
description.add_action(tf_node_1)
description.add_action(tf_node_2)
description.add_action(laserscan_virtualizer)
return description