mirror of https://github.com/ArduPilot/ardupilot
AP_Compass: Use SITL singleton
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
This commit is contained in:
parent
37fbd6aaa1
commit
e456655932
|
@ -6,10 +6,10 @@
|
|||
extern const AP_HAL::HAL& hal;
|
||||
|
||||
AP_Compass_SITL::AP_Compass_SITL(Compass &compass):
|
||||
_sitl(AP::sitl()),
|
||||
_has_sample(false),
|
||||
AP_Compass_Backend(compass)
|
||||
{
|
||||
_sitl = (SITL::SITL *)AP_Param::find_object("SIM_");
|
||||
if (_sitl != nullptr) {
|
||||
_compass._setup_earth_field();
|
||||
for (uint8_t i=0; i<SITL_NUM_COMPASSES; i++) {
|
||||
|
|
Loading…
Reference in New Issue