From 105125da0acf1559053e96e7cd8084b4050c5c88 Mon Sep 17 00:00:00 2001 From: Rutvik Patel Date: Tue, 21 Jun 2022 18:01:41 +0530 Subject: [PATCH] Add home_service.sh script --- my_robot/launch/view_navigation.launch | 2 +- scripts/home_service.sh | 27 ++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 scripts/home_service.sh diff --git a/my_robot/launch/view_navigation.launch b/my_robot/launch/view_navigation.launch index dca4c48..febc316 100644 --- a/my_robot/launch/view_navigation.launch +++ b/my_robot/launch/view_navigation.launch @@ -3,7 +3,7 @@ \ No newline at end of file diff --git a/scripts/home_service.sh b/scripts/home_service.sh new file mode 100644 index 0000000..789cd4d --- /dev/null +++ b/scripts/home_service.sh @@ -0,0 +1,27 @@ +#!/bin/sh + +# Move to catkin_ws root +cd ../../ + +# Launch the world containing the robot +xterm -e " source devel/setup.bash; roslaunch my_robot world.launch " & + +sleep 10 + +# Launch amcl package for localization +xterm -e " source devel/setup.bash; roslaunch my_robot amcl.launch " & + +sleep 5 + +# Launch rviz to localize the results +xterm -e " source devel/setup.bash; roslaunch my_robot view_navigation.launch " & + +sleep 5 + +# Launch add_markers to vizualize objects in rviz +xterm -e " source devel/setup.bash; roslaunch my_robot add_markers.launch " & + +sleep 5 + +# Launch pick_object to guide robot across the map +xterm -e " source devel/setup.bash; roslaunch my_robot pick_objects.launch " & \ No newline at end of file