Skip to content

Commit

Permalink
Split launch NAND and SC launch files
Browse files Browse the repository at this point in the history
  • Loading branch information
PatXue committed Mar 18, 2024
1 parent 26935a2 commit 44a3711
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 0 deletions.
File renamed without changes.
42 changes: 42 additions & 0 deletions rb_ws/src/buggy/launch/sc-main.launch
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<!-- roslaunch buggy main.launch -->

<launch>
<arg name="controller" default="mpc" />
<arg name="start_dist" default="0.0" />
<arg name="path" default="buggycourse_safe_1.json" />

<include file="$(find microstrain_inertial_driver)/launch/microstrain.launch">
<arg name="params_file" value="/rb_ws/src/buggy/INS_params.yml"/>
</include>

<remap from="/SC/nav/odom" to="/nav/odom"/>
<remap from="/buggy/input/steering" to="/SC/buggy/input/steering"/>

<node name="serial_node" pkg="rosserial_python" type="serial_node.py">
<param name="port" type="string" value="/dev/ttyUSB0"/>
<param name="baud" type="int" value="1000000"/>
</node>
<node name="serial_node2" pkg="rosserial_python" type="serial_node.py">
<param name="port" type="string" value="/dev/ttyACM1"/>
<param name="baud" type="int" value="115200"/>
</node>
<node name="foxglove" pkg="foxglove_bridge" type="foxglove_bridge" />
<node name="telematics" pkg="buggy" type="telematics.py" />




<!-- ENABLE AUTON -->
<!-- autonsystem args: controller start_dist path buggy_name is_sim -->
<!-- Conditional Launch Files, depending on if NAND Exists or not -->
<arg name="NAND_exist" default="true"/>
<group if="$(arg NAND_exist)">
<!-- Run the simulation with NAND -->
<arg name="autonsystem_args" default="--controller $(arg controller) --dist 0.0 --traj $(arg path) --self_name SC --other_name NAND" />
<node name="auton_system" pkg="buggy" type="autonsystem.py" output="screen" args="$(arg autonsystem_args)"/>
</group>
<group unless="$(arg NAND_exist)">
<arg name="autonsystem_args" default="--controller $(arg controller) --dist 0.0 --traj $(arg path) --self_name SC" />
<node name="auton_system" pkg="buggy" type="autonsystem.py" output="screen" args="$(arg autonsystem_args)"/>
</group>
</launch>

0 comments on commit 44a3711

Please sign in to comment.