mirror of https://github.com/ArduPilot/ardupilot
Sub: fixed startup order of setting mavlink system ID
Set sysid from param before you init the serial port so you always output the intended sysid. Ported the same fix as c01a7718c1
This commit is contained in:
parent
a960c6526c
commit
51fa76d971
|
@ -32,6 +32,9 @@ void Sub::init_ardupilot()
|
|||
|
||||
BoardConfig.init();
|
||||
|
||||
// identify ourselves correctly with the ground station
|
||||
mavlink_system.sysid = g.sysid_this_mav;
|
||||
|
||||
// initialise serial port
|
||||
serial_manager.init();
|
||||
|
||||
|
@ -60,9 +63,6 @@ void Sub::init_ardupilot()
|
|||
gcs_chan[i].setup_uart(serial_manager, AP_SerialManager::SerialProtocol_MAVLink, i);
|
||||
}
|
||||
|
||||
// identify ourselves correctly with the ground station
|
||||
mavlink_system.sysid = g.sysid_this_mav;
|
||||
|
||||
#if LOGGING_ENABLED == ENABLED
|
||||
log_init();
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue