mirror of https://github.com/ArduPilot/ardupilot
AP_Compass: setup for fmuv6
This commit is contained in:
parent
c0e6338d8a
commit
7f3103073a
|
@ -667,7 +667,8 @@ void Compass::_probe_external_i2c_compasses(void)
|
|||
}
|
||||
|
||||
// IST8310 on external and internal bus
|
||||
if (AP_BoardConfig::get_board_type() != AP_BoardConfig::PX4_BOARD_FMUV5) {
|
||||
if (AP_BoardConfig::get_board_type() != AP_BoardConfig::PX4_BOARD_FMUV5 &&
|
||||
AP_BoardConfig::get_board_type() != AP_BoardConfig::PX4_BOARD_FMUV6) {
|
||||
enum Rotation default_rotation;
|
||||
|
||||
if (AP_BoardConfig::get_board_type() == AP_BoardConfig::PX4_BOARD_AEROFC) {
|
||||
|
@ -739,6 +740,7 @@ void Compass::_detect_backends(void)
|
|||
case AP_BoardConfig::PX4_BOARD_PIXRACER:
|
||||
case AP_BoardConfig::PX4_BOARD_MINDPXV2:
|
||||
case AP_BoardConfig::PX4_BOARD_FMUV5:
|
||||
case AP_BoardConfig::PX4_BOARD_FMUV6:
|
||||
case AP_BoardConfig::PX4_BOARD_PIXHAWK_PRO:
|
||||
case AP_BoardConfig::PX4_BOARD_AEROFC:
|
||||
_probe_external_i2c_compasses();
|
||||
|
@ -792,6 +794,7 @@ void Compass::_detect_backends(void)
|
|||
break;
|
||||
|
||||
case AP_BoardConfig::PX4_BOARD_FMUV5:
|
||||
case AP_BoardConfig::PX4_BOARD_FMUV6:
|
||||
FOREACH_I2C_EXTERNAL(i) {
|
||||
ADD_BACKEND(DRIVER_IST8310, AP_Compass_IST8310::probe(GET_I2C_DEVICE(i, HAL_COMPASS_IST8310_I2C_ADDR),
|
||||
true, ROTATION_ROLL_180_YAW_90));
|
||||
|
|
Loading…
Reference in New Issue