Skip to content

Commit

Permalink
Update mavproxy configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
JcZou committed Jul 2, 2023
1 parent 3a18599 commit 7c60d00
Showing 1 changed file with 17 additions and 4 deletions.
21 changes: 17 additions & 4 deletions docs/introduction/configuration/mavproxy_config.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,37 @@

The mavproxy module implements mavlink protocol and it is responsible for mavlink data communication, including message sending and reception.

`[mavproxy]` table is used to configure the mavproxy module, which contains one or more `[[mavproxy.devices]]` that the mavproxy can use. The bellowing is a valid configuration with two devices reserved for mavproxy. They are *serial1*, and *usb0* respectively grouped by *[[console.devices]]* subtables.
`[mavproxy]` table is used to configure the mavproxy module, which supports multiple channels (`currently 2 channels are supported, channel 0 for GCS and channel 1 for onboard computer`) and each channel can defines one or more `[[mavproxy.devices]]` that the mavproxy channel can use. The bellowing is a valid configuration with two devices reserved for channel0 and one device for channel1 .

The system will use the first device by default (serial1 in this case) and mavproxy can switch to usb0 if usb is connected. When usb disconnected, the mavproxy will switch back to serial1 device.
The system will use the first device by default for mavproxy channel and is able to switch to other devices if multiple devices defined for the channel. For instance, mavproxy channel0 can switch to usb0 if usb is connected. When usb disconnected, the mavproxy channel0 will switch back to serial1 device.

```
[mavproxy]
[[mavproxy.devices]] # channel 0
[[mavproxy.devices]]
chan = 0 # channel 0 (GCS) device
type = "serial"
name = "serial1" # device name
baudrate = 57600 # serial baudrate
[[mavproxy.devices]] # channel 1
[[mavproxy.devices]]
chan = 0 # channel 0 (GCS) device
type = "usb"
name = "usbd0" # device name
# automatically switch to usb if connected, switch back to default device is disconnected
auto-switch = true
[[mavproxy.devices]]
chan = 1 # channel 1 (Onboard Computer) device
type = "serial"
name = "serial2"
baudrate = 115200
```

The **chan** has following choices:

- 0: Channel for ground control station.
- 1: Channel for onboard computer.

The **type** has following choices:

- **serial**: the general serial device.
Expand Down

0 comments on commit 7c60d00

Please sign in to comment.