-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Supply launch_file as cmdline to the base script
Signed-off-by: Aditya Pande <[email protected]>
- Loading branch information
1 parent
4276497
commit ba42a2b
Showing
3 changed files
with
23 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,13 @@ | ||
import subprocess | ||
import sys | ||
|
||
print("Hello world from roslaunch_base") | ||
print("ARGS: ", sys.argv[1:]) | ||
launch_file_name = sys.argv[1] | ||
launch_file_dir = "ros2_example_apps" | ||
|
||
subprocess.run(["./external/ros2/ros2", "launch", "ros2_example_apps/eg_launch.py"]) | ||
roslaunch_cli = "./external/ros2/ros2" | ||
action = "launch" | ||
launch_file = launch_file_dir + "/" + launch_file_name | ||
|
||
subprocess.run([roslaunch_cli, action, launch_file]) | ||
# subprocess.run(["/bin/bash"]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters