AP_HAL_SITL: Add instance to ADSB simulation

This commit is contained in:
Stephen Dade 2021-10-20 12:12:00 +11:00 committed by Peter Barker
parent 016edd28fc
commit 1356beb14d

View File

@ -180,7 +180,7 @@ void SITL_State::_fdm_input_step(void)
if (_sitl->adsb_plane_count >= 0 &&
adsb == nullptr) {
adsb = new SITL::ADSB(_sitl->state, sitl_model->get_home());
adsb = new SITL::ADSB(_sitl->state, sitl_model->get_home(), get_instance());
} else if (_sitl->adsb_plane_count == -1 &&
adsb != nullptr) {
delete adsb;