AP_Baro: don't compile drivers for devices that don't use them
This commit is contained in:
parent
156efd6fec
commit
fb24a03faf
@ -406,9 +406,11 @@ void AP_Baro::init(void)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case AP_BoardConfig::PX4_BOARD_AEROFC:
|
case AP_BoardConfig::PX4_BOARD_AEROFC:
|
||||||
|
#ifdef HAL_BARO_MS5607_I2C_BUS
|
||||||
ADD_BACKEND(AP_Baro_MS56XX::probe(*this,
|
ADD_BACKEND(AP_Baro_MS56XX::probe(*this,
|
||||||
std::move(hal.i2c_mgr->get_device(HAL_BARO_MS5607_I2C_BUS, HAL_BARO_MS5607_I2C_ADDR)),
|
std::move(hal.i2c_mgr->get_device(HAL_BARO_MS5607_I2C_BUS, HAL_BARO_MS5607_I2C_ADDR)),
|
||||||
AP_Baro_MS56XX::BARO_MS5607));
|
AP_Baro_MS56XX::BARO_MS5607));
|
||||||
|
#endif
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
Loading…
Reference in New Issue
Block a user