From 164a064b82a0b266c2683620479df1511d30f5e5 Mon Sep 17 00:00:00 2001 From: Jonty-Clark Date: Sun, 24 Nov 2024 11:41:02 +1300 Subject: [PATCH 1/3] path_planning_visualiser launchfile --- .../launch/path_planning_visualiser.launch.py | 22 +++++++++++++++++++ .../path_planning_visualiser/setup.py | 4 ++++ 2 files changed, 26 insertions(+) create mode 100644 src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py diff --git a/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py b/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py new file mode 100644 index 0000000..e8b66e0 --- /dev/null +++ b/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py @@ -0,0 +1,22 @@ +from launch import LaunchDescription +from launch_ros.actions import Node + +def generate_launch_description(): + return LaunchDescription([ + package_name = 'path_planning_visualiser' + Node( + package=package_name, + executable='visualise_action_demo', + name='visualise_action_demo' + ), + Node( + package=package_name, + executable='visualise_trajectories_demo', + name='visualise_trajectories_demo' + ), + Node( + package=package_name, + executable='visualise_trajectories', + name='visualise_trajectories' + ) + ]) \ No newline at end of file diff --git a/src/visualisation/path_planning_visualiser/setup.py b/src/visualisation/path_planning_visualiser/setup.py index f0791af..d7fe2ad 100644 --- a/src/visualisation/path_planning_visualiser/setup.py +++ b/src/visualisation/path_planning_visualiser/setup.py @@ -1,4 +1,6 @@ from setuptools import find_packages, setup +import os +from glob import glob package_name = 'path_planning_visualiser' @@ -10,6 +12,8 @@ ('share/ament_index/resource_index/packages', ['resource/' + package_name]), ('share/' + package_name, ['package.xml']), + # launch files + (os.path.join('share', package_name, 'launch'), glob(os.path.join('launch', '*.py*'))), ], install_requires=['setuptools'], zip_safe=True, From dae7cc1f272ee5327dc2e49889d70fd5a5c6f781 Mon Sep 17 00:00:00 2001 From: Jonty-Clark Date: Sun, 24 Nov 2024 17:10:52 +1300 Subject: [PATCH 2/3] Errors fixed --- .../launch/path_planning_visualiser.launch.py | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py b/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py index e8b66e0..e29886c 100644 --- a/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py +++ b/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py @@ -3,20 +3,14 @@ def generate_launch_description(): return LaunchDescription([ - package_name = 'path_planning_visualiser' Node( - package=package_name, - executable='visualise_action_demo', - name='visualise_action_demo' - ), - Node( - package=package_name, - executable='visualise_trajectories_demo', + package='path_planning_visualiser', + executable='visualiser2', name='visualise_trajectories_demo' ), Node( - package=package_name, - executable='visualise_trajectories', + package='path_planning_visualiser', + executable='visualiser', name='visualise_trajectories' ) ]) \ No newline at end of file From e520e59a6ec0588b37205ac9442c67c41dea706b Mon Sep 17 00:00:00 2001 From: Jonty-Clark Date: Sun, 24 Nov 2024 17:20:09 +1300 Subject: [PATCH 3/3] Comment at top --- .../launch/path_planning_visualiser.launch.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py b/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py index e29886c..04b947d 100644 --- a/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py +++ b/src/visualisation/path_planning_visualiser/launch/path_planning_visualiser.launch.py @@ -1,3 +1,5 @@ +#Command to launch: ros2 launch path_planning_visualiser path_planning_visualiser.launch.py + from launch import LaunchDescription from launch_ros.actions import Node