Andrew Tridgell
536222859d
AP_Compass: added COMPASS_OPTIONS
...
this allows user to set that calibration requires GPS lock
2019-12-09 13:18:01 +11:00
Andrew Tridgell
920007f3c4
AP_Compass: added estimation of compass scale factor
...
this adds new COMPASS_SCALE, COMPASS_SCALE2 and COMPASS_SCALE3
parameters, which give the sensor scaling factor. It is used to
compensate for an incorrect scaling in a compass.
The 3D compass calibration process will set the correct value
automatically, otherwise users can set the value to a known value for
an existing compass
2019-12-09 13:18:01 +11:00
Andrew Tridgell
2a48241ebb
AP_Compass: fixed naming of QMC5883L driver
...
needed for probe using COMPASS macro in hwdef.dat
2019-09-04 16:27:47 +10:00
Andrew Tridgell
f4576ec8f3
AP_Compass: reduce firmware size for AP_Periph
2019-08-27 10:29:56 +10:00
Peter Barker
1adda1ccf0
AP_Compass: move automatic declination setting into AP_Compass itself
2019-08-13 10:02:13 +10:00
Peter Barker
df01bed14f
AP_Compass: take GCS link in place of channel to calibration routines
2019-08-05 09:23:10 +10:00
Michael du Breuil
9fc954b030
AP_Compass: Reduce scope of BattMonitor include
2019-06-18 10:02:05 +10:00
Andrew Tridgell
532b82b3a3
AP_Compass: use DRIVER_HMC5843 to match driver name
2019-05-30 15:39:57 +10:00
Peter Barker
bf23f1df67
AP_Compass: move responsibility for logging into library
2019-04-23 10:06:17 +10:00
Peter Barker
0e8722181f
AP_Compass: take responsibility for not running cal if armed
2019-04-23 10:06:17 +10:00
Peter Barker
7ae7c48362
AP_Compass: remove set_and_save_offsets taking integer parameters
...
because the only caller that mattered had floats to offer...
2019-04-05 06:09:25 -07:00
Peter Barker
54e3959a99
AP_Compass: move enabled parameter into compass library
2019-04-02 10:24:49 +11:00
Peter Barker
f8be4efed4
AP_Compass: init never fails; return void rather than bool
2019-03-13 13:06:50 +11:00
thomass
8155c8b178
AP_Compass: added backend implementation for RM3100 compass
2019-02-10 08:00:49 +11:00
Lucas De Marchi
34fb98b1e0
AP_Compass: probe for IST8308 on external buses
2018-10-25 20:19:30 -07:00
Andrew Tridgell
5ac6309848
AP_Compass: enable in-flight compass learning system
...
using COMPASS_LEARN=3
2018-10-24 07:25:42 +10:00
Andrew Tridgell
925555c995
AP_Compass: move accum fields to frontend
...
this is needed to ensure they are per-instance. Without this the SITL
backend produces zero for all but the first instance. The same would
be true for any multi-instance backend
2018-10-17 12:54:22 +11:00
Lucas De Marchi
de535dc573
AP_Compass: remove unused external and name arguments
...
Aka "fix copy and pasta".
2018-09-06 08:23:02 +10:00
Jonathan Challinger
cefd998177
AP_Compass: add expected DEV_ID parameters
2018-08-07 10:00:10 +10:00
Jonathan Challinger
878e84a015
AP_Compass: correct edge case where checks pass when saved dev_id != detected dev_id
2018-08-07 10:00:10 +10:00
Randy Mackay
99b54935db
Compass: remove accumulate
...
this method is a noop on all backends
2018-08-06 11:05:34 +10:00
Andrew Tridgell
8b0f40b402
AP_Compass: implement automatic compass orientation
...
this automatically determines the compass orientation when doing a 3D
compass calibration, if COMPASS_ROT_AUTO is enabled.
2018-07-18 16:07:19 +10:00
Andrew Tridgell
ff6d639ed7
AP_Compass: separated out external compass probing
...
this allows any ChibiOS board to specify that it wants to probe for
all possible external compass types with a define in hwdef.dat
It also implements duplicate compass detection for all i2c drivers,
ensuring we can't get a load of a driver on the same bus/address twice
2018-07-14 17:51:50 +10:00
Peter Barker
051c811bfb
AP_Compass: make compass_cal_requires_reboot const
2018-07-03 13:44:11 +10:00
Peter Barker
4c2925d693
AP_Compass: remove pointless initialisations
...
If you are allocating one of these on the stack you're doing something
wrong.
2018-07-02 10:44:34 +10:00
Peter Barker
a3a1967e05
AP_Compass: add AP::compass() singleton getter
2018-05-17 15:37:14 +10:00
Francisco Ferreira
0a3af28d17
AP_Compass: remove Qualcomm board support
2018-05-17 09:57:20 +10:00
Jacob Walser
6699c59ad3
AP_Compass: add support for custom board orientations
2018-04-24 13:04:37 +01:00
night-ghost
f26bb0cfbe
AP_Compass: added range filter to backend, added its use in some sensors (thanks khancyr for style correction)
2018-04-11 14:46:42 +10:00
Michael du Breuil
c66d15efd7
AP_Compass: Read current for compensation from the battery singleton
2018-03-27 22:12:21 +01:00
Andrew Tridgell
487b615faa
AP_Compass: allow for override of MAG_BOARD_ORIENTATION
2018-03-02 12:52:50 +11:00
Andrew Tridgell
57a3bc1397
AP_Compass: new compass learning system
...
this learns compass offsets using magnetic tables and compass
observations
2018-02-08 17:36:33 +11:00
Andrew Tridgell
ca30f6aec8
AP_Compass: added per-motor compass calibration
...
this allows for a motor calibration vector per motor
2018-02-08 17:36:33 +11:00
night-ghost
b6bf90ab93
AP_Compass: mAG3110 driver
2018-02-02 21:07:40 +11:00
Andrew Tridgell
f326377a5c
AP_Compass: removed create() method for objects
...
See discussion here:
https://github.com/ArduPilot/ardupilot/issues/7331
we were getting some uninitialised variables. While it only showed up in
AP_SbusOut, it means we can't be sure it won't happen on other objects,
so safest to remove the approach
Thanks to assistance from Lucas, Peter and Francisco
2017-12-14 08:12:28 +11:00
Andrew Tridgell
5646afac1c
AP_Compass: avoid double detection of the AK09916
...
with an ICM20948 we can double detect the compass due to the i2c pass-thru
2017-10-04 11:49:06 +11:00
Lucas De Marchi
320260a151
AP_Compass: add static create method
2017-09-26 03:01:21 +01:00
Lucas De Marchi
b1740e2d9c
AP_Compass: remove raspilot
2017-09-12 15:06:19 -07:00
Andrew Tridgell
732dc5984a
AP_Compass: added COMPASS_TYPEMASK parameter
...
this allows driver type to be disabled, to avoid probing them and
wasting CPU on sensors that are not being used
This also moves UAVCAN compass to be detected last, as discussed in the
dev call
2017-07-19 15:53:22 +10:00
Peter Barker
6b53b5b5f3
AP_Compass: make handle_mag_cal_command return type stricter
2017-07-17 14:17:19 +01:00
Miguel Arroyo
ee328c9683
AP_Compass: move SITL Compass to standard sensor backend model
2017-06-29 09:22:08 +10:00
Andrew Tridgell
ee2afd3242
AP_Compass: added COMPASS_OFFS_MAX
...
this allows setup of airframes with hatch magnets
2017-04-04 00:49:34 +01:00
Randy Mackay
855125381d
AP_Compass: relax compass cal fitness and consistency checks
2017-01-27 11:20:02 +09:00
Randy Mackay
53d1585ebf
Compass: relax compass consistency checks for pixracer
2017-01-21 12:10:00 +09:00
Randy Mackay
0c4e3cd8e4
Compass: pixracer calibration fitness default relaxed
2017-01-21 10:15:11 +09:00
Andrew Tridgell
2716ab8408
AP_Compass: added support for per-instance rotations
2016-11-09 17:08:08 +11:00
Andrew Tridgell
147b253e65
AP_Compass: make device IDs match PX4 drivers
...
match in-tree drivers to PX4Firmware drivers
2016-11-09 17:08:06 +11:00
Andrew Tridgell
de7913e8e9
AP_Compass: implement device IDs for compass drivers
2016-11-09 17:08:04 +11:00
Michael du Breuil
deec4ec6af
Compass: Rework compass calibrator
...
Summary of significant changes:
-Autsave doesn't depend on STREAM_EXTRA3
-Don't risk only saving one compass on copter if CAL_ALWAYS_REBOOT is set
-Only calibrate compasses that are both health and marked for use (there was a inconsistency in handling the mask)
-Fix incorrect failure reporting on DO_ACCEPT_MAG_CAL with a mask of 0 if a channel was specifically not started
-Fix not starting the buzzer if the delay is set to 0 seconds
-Always send MAG_CAL_REPORT until its acknowledged
-Correct the field in MAG_CAL_REPORT for autosave to indicate if the compass had actually been saved, rather then being scheduled to be saved
-Remmove unused public interfaces
2016-10-27 14:04:33 +11:00
Mathieu OTHACEHE
152edf7189
Global: remove mode line from headers
...
Using a global .dir-locals.el file is a better alternative than
reincluding the same emacs header in every file of the project.
2016-10-24 09:42:01 -02:00