<!--
  Copyright: 2016-2020 ROS小课堂 www.corvin.cn
  Description:robot启动时最先需要启动的launch文件，主要加载各基础功能模块启动。
    首先就需要启动机器人的urdf文件,这样就可以在rviz中可视化显示机器人模型.然后
    启动下位机arduino的程序,上下位机建立连接,这样上位机就可以发送控制命令.接下来
    启动IMU模块,开始发布姿态信息.接下来就开始进行信息融合,使用imu信息和轮式里程计
    这样得出的里程计更为准确.
  Author: corvin
  History:
    20200716:init this file.
-->
<launch>
    <!-- (1) startup robot urdf description -->
    <!--include file="$(find robot_description)/launch/robot_description.launch" /-->

    <!-- (2) startup mobilebase arduino launch -->
    <include file="$(find ros_arduino_python)/launch/arduino.launch" />

    <!-- (3) startup rasp imu-6DOF board-->
    <include file="$(find rasp_imu_hat_6dof)/launch/imu_data_pub.launch" />

    <!-- (4) startup rasp cam-->
    <include file="$(find rasp_camera)/launch/rasp_camera.launch" />

    <!-- (5) startup robot_pose_ekf node -->
    <node pkg="robot_pose_ekf" type="robot_pose_ekf" name="robot_pose_ekf">
        <param name="output_frame" value="odom_combined"/>
        <param name="freq" value="10.0"/>
        <param name="sensor_timeout" value="1.2"/>
        <param name="odom_used" value="true"/>
        <param name="imu_used" value="true"/>
        <param name="vo_used" value="false"/>
        <param name="debug" value="false"/>
        <param name="self_diagnose" value="false"/>
    </node>

    <!-- (6) /odom_combined view in rviz -->
    <node pkg="robot_bringup" type="odom_ekf.py" name="odom_ekf" output="screen">
        <remap from="input" to="/robot_pose_ekf/odom_combined" />
        <remap from="output" to="/odom_ekf" />
    </node>
</launch>
