AP_AHRS: Use SITL singleton

Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
This commit is contained in:
Patrick José Pereira 2018-05-10 20:32:06 -03:00 committed by Francisco Ferreira
parent a0b4553a26
commit 819f08b7f7

View File

@ -291,7 +291,7 @@ void AP_AHRS_NavEKF::update_EKF3(void)
void AP_AHRS_NavEKF::update_SITL(void)
{
if (_sitl == nullptr) {
_sitl = (SITL::SITL *)AP_Param::find_object("SIM_");
_sitl = AP::sitl();
if (_sitl == nullptr) {
return;
}