mirror of https://github.com/ArduPilot/ardupilot
AP_ExternalAHRS: correct AP_ExternalAHRS init
default clause is in wrong place and shouldn't be present to start with...
This commit is contained in:
parent
3cfa13c0b2
commit
f8f28ee767
|
@ -92,21 +92,20 @@ void AP_ExternalAHRS::init(void)
|
||||||
switch (DevType(devtype)) {
|
switch (DevType(devtype)) {
|
||||||
case DevType::None:
|
case DevType::None:
|
||||||
// nothing to do
|
// nothing to do
|
||||||
break;
|
return;
|
||||||
#if AP_EXTERNAL_AHRS_VECTORNAV_ENABLED
|
#if AP_EXTERNAL_AHRS_VECTORNAV_ENABLED
|
||||||
case DevType::VecNav:
|
case DevType::VecNav:
|
||||||
backend = new AP_ExternalAHRS_VectorNav(this, state);
|
backend = new AP_ExternalAHRS_VectorNav(this, state);
|
||||||
break;
|
return;
|
||||||
#endif
|
#endif
|
||||||
#if AP_EXTERNAL_AHRS_MICROSTRAIN5_ENABLED
|
#if AP_EXTERNAL_AHRS_MICROSTRAIN5_ENABLED
|
||||||
case DevType::MicroStrain5:
|
case DevType::MicroStrain5:
|
||||||
backend = new AP_ExternalAHRS_MicroStrain5(this, state);
|
backend = new AP_ExternalAHRS_MicroStrain5(this, state);
|
||||||
break;
|
return;
|
||||||
default:
|
|
||||||
#endif
|
#endif
|
||||||
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Unsupported ExternalAHRS type %u", unsigned(devtype));
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Unsupported ExternalAHRS type %u", unsigned(devtype));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool AP_ExternalAHRS::enabled() const
|
bool AP_ExternalAHRS::enabled() const
|
||||||
|
|
Loading…
Reference in New Issue