mirror of https://github.com/ArduPilot/ardupilot
AP_Compass: support ChibiOS FMUv4
This commit is contained in:
parent
c7fd455f6a
commit
743714de4c
|
@ -534,7 +534,7 @@ void Compass::_detect_backends(void)
|
|||
return;
|
||||
}
|
||||
|
||||
#if CONFIG_HAL_BOARD == HAL_BOARD_PX4
|
||||
#if AP_FEATURE_BOARD_DETECT
|
||||
if (AP_BoardConfig::get_board_type() == AP_BoardConfig::PX4_BOARD_PIXHAWK2) {
|
||||
// default to disabling LIS3MDL on pixhawk2 due to hardware issue
|
||||
_driver_type_mask.set_default(1U<<DRIVER_LIS3MDL);
|
||||
|
@ -560,7 +560,7 @@ void Compass::_detect_backends(void)
|
|||
|
||||
#if HAL_COMPASS_DEFAULT == HAL_COMPASS_HIL
|
||||
ADD_BACKEND(DRIVER_SITL, AP_Compass_HIL::detect(*this), nullptr, false);
|
||||
#elif HAL_COMPASS_DEFAULT == HAL_COMPASS_PX4 || HAL_COMPASS_DEFAULT == HAL_COMPASS_VRBRAIN || defined(HAL_CHIBIOS_ARCH_FMUV3)
|
||||
#elif AP_FEATURE_BOARD_DETECT
|
||||
switch (AP_BoardConfig::get_board_type()) {
|
||||
case AP_BoardConfig::PX4_BOARD_PX4V1:
|
||||
case AP_BoardConfig::PX4_BOARD_PIXHAWK:
|
||||
|
|
Loading…
Reference in New Issue