AP_HAL_SITL: create and use ADSB sim when mxs simulator is in play

This commit is contained in:
Peter Barker 2023-10-31 19:08:12 +11:00 committed by Peter Barker
parent 3edaea9be9
commit c06a759710
1 changed files with 4 additions and 0 deletions

View File

@ -216,6 +216,10 @@ SITL::SerialDevice *SITL_State_Common::create_serial_sim(const char *name, const
AP_HAL::panic("Only one sagetech_mxs at a time");
}
sagetech_mxs = new SITL::ADSB_Sagetech_MXS();
if (adsb == nullptr) {
adsb = new SITL::ADSB();
}
sitl_model->set_adsb(adsb);
return sagetech_mxs;
#endif
#if !defined(HAL_BUILD_AP_PERIPH)