from launch import LaunchDescription
import launch_ros.actions


def generate_launch_description():
    robot_parameters = [
        {'usart_port_name': '/dev/ttyACM0',
         'serial_baud_rate': 115200,
         'robot_frame_id': 'base_footprint',
         'odom_frame_id': 'odom',
         'combined_odom_topic': 'odom_combined',
         'scan_topic': '/scan',
         'wall_config_path': '/home/sunrise/yiliao_ws/src/origincar_base/config/wall_fit.json',
         'publish_tf': True,
         'wall_scan_stride': 2,
         'cmd_vel': 'cmd_vel',
         'akm_cmd_vel': 'none',
         'product_number': 0,
         'gyro_z_low_pass_alpha': 0.6,
         'odom_pose_cov_x': 0.01,
         'odom_pose_cov_y': 0.01,
         'odom_pose_cov_yaw': 0.0225}
    ]

    return LaunchDescription([
        launch_ros.actions.Node(
            package='origincar_base',
            executable='origincar_base_node',
            parameters=robot_parameters,
        )
    ])
