Files
PX4-Autopilot/boards/atl/mantis-edu/init/rc.board_mavlink
T
Daniel Agar 6d78054f50 mavlink USB auto start/stop on boards with VBUS
- no longer start sercon or mavlink usb by default
 - on USB connection (VBUS) monitor serial USB at low rate and start Mavlink if there's a HEARTBEAT or nshterm on 3 consecutive carriage returns
 - the mavlink USB instance is automatically stopped and serdis executed if USB is disconnected
 - skipping Mavlink USB (and sercon) saves a considerable amount of memory on older boards
2021-10-03 15:32:54 -04:00

17 lines
522 B
Bash

#!/bin/sh
#
# board specific MAVLink startup script.
#------------------------------------------------------------------------------
set GIMBAL_TTY /dev/ttyS3
set MAV_RATE 40000
set BAUDRATE 500000
mavlink start -r ${MAV_RATE} -d ${GIMBAL_TTY} -b ${BAUDRATE}
mavlink stream -d ${GIMBAL_TTY} -s SYSTEM_TIME -r 0.5
mavlink stream -d ${GIMBAL_TTY} -s AUTOPILOT_STATE_FOR_GIMBAL_DEVICE -r 20
mavlink stream -d ${GIMBAL_TTY} -s GIMBAL_DEVICE_SET_ATTITUDE -r 20
# optical flow
mavlink start -d /dev/ttyS2 -m custom -b 500000