Browse Source

AP_Compass: fixed showing of is_external for 2nd compass

mission-4.1.18
Andrew Tridgell 11 years ago
parent
commit
db48ed9218
  1. 2
      libraries/AP_Compass/AP_Compass_PX4.cpp

2
libraries/AP_Compass/AP_Compass_PX4.cpp

@ -64,7 +64,7 @@ bool AP_Compass_PX4::init(void)
// remember if the compass is external // remember if the compass is external
_is_external[i] = (ioctl(_mag_fd[i], MAGIOCGEXTERNAL, 0) > 0); _is_external[i] = (ioctl(_mag_fd[i], MAGIOCGEXTERNAL, 0) > 0);
if (_is_external[0]) { if (_is_external[i]) {
hal.console->printf("Using external compass[%u]\n", (unsigned)i); hal.console->printf("Using external compass[%u]\n", (unsigned)i);
} }
_count[0] = 0; _count[0] = 0;

Loading…
Cancel
Save