Commit 8af889d4 authored by Robert Haschke's avatar Robert Haschke
Browse files

launch: conditionally start rosbag play or cameras

If argument bag is present, start rosbag replay, otherwise use cams.
parent f340981b
......@@ -3,9 +3,10 @@
<launch>
<arg name="rviz_config" default="$(find aruco_tracking)/launch/aruco_config.rviz" />
<arg name="aruco_params" default="$(find aruco_tracking)/config/aruco_params_extended.yaml" />
<arg name="bag" default="" />
<!-- RVIZ -->
<node name="rviz" pkg="rviz" type="rviz" args="-d $(arg rviz_config)" />
<node name="rviz" pkg="rviz" type="rviz" args="-d $(arg rviz_config)" required="true" />
<group ns="aruco_tracking">
<arg name="manager_name" value="aruco_manager" />
......@@ -34,4 +35,12 @@
<node name="tracking" pkg="aruco_tracking" type="track_boards.py" output="screen" />
</group>
<!-- Either start rosbag play (if argument 'bag' is present) -->
<node if="$(eval bool(bag))" name="rosbag_play" pkg="rosbag" type="play" args="-l $(arg bag)" />
<!-- or start real cameras -->
<group if="$(eval not bag)">
<include file="$(dirname)/usb_cam_camhs4.launch" />
<include file="$(dirname)/usb_cam_camhs6.launch" />
</group>
</launch>
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment