Commit Graph

13 Commits

Author SHA1 Message Date
Andrew Tridgell 75ea8f3dc0 AP_InertialSensor: removed "have sample" logic from drivers
the frontend has all the information it needs, so we can simplify the
drivers some more
2015-11-16 17:57:35 +11:00
Andrew Tridgell 0e4bab74ba AP_InertialSensor: simplify sensor backends
use common code for filtering and update, allowing each sensor driver
to be simpler and more consistent
2015-11-16 17:57:35 +11:00
Lucas De Marchi 5244559010 Minimize AP_Progmem.h includes
Most of AP_Progmem is already gone so we can stop including it in most
of the places. The only places that need it are the ones using
pgm_read_*() APIs.

In some cases the header needed to be added in the .cpp since it was
removed from the .h to reduce scope. In those cases the headers were
also reordered.
2015-10-30 14:35:32 +09:00
Gustavo Jose de Sousa 7789aec85b AP_InertialSensor: standardize inclusion of libaries headers
This commit changes the way libraries headers are included in source files:

 - If the header is in the same directory the source belongs to, so the
 notation '#include ""' is used with the path relative to the directory
 containing the source.

 - If the header is outside the directory containing the source, then we use
 the notation '#include <>' with the path relative to libraries folder.

Some of the advantages of such approach:

 - Only one search path for libraries headers.

 - OSs like Windows may have a better lookup time.
2015-08-11 16:28:43 +10:00
mirkix 13ee34c58a AP_InertialSensor: MPU9150 fix compiler warnings 2015-04-14 11:14:48 +10:00
Andrew Tridgell 3d7d46b9b0 AP_InertialSensor: replaced INS_MPU6K_FILTER with INS_ACCEL_FILTER and INS_GYRO_FILTER
this allows filtering to be set separately on accels and gyros where possible
2015-03-12 12:50:31 +11:00
Jonathan Challinger 502446d821 AP_InertialSensor: use LowPassFilter2pVector3f 2015-03-12 12:50:27 +11:00
Andrew Tridgell a047d1f569 AP_InertialSensor: moved default filter and sample_rate to frontend
this simplifies the backends and prevents code repitition
2014-10-24 12:10:40 +11:00
Andrew Tridgell dbcd02f2be AP_InertialSensor: converted MPU9150 driver
untested conversion
2014-10-24 12:10:38 +11:00
Andrew Tridgell abb53eb9a2 AP_InertialSensor: simplify using HAL board subtypes 2014-07-14 09:44:35 +10:00
Víctor Mayoral Vilches 7cf1187473 AP_InertialSensor_MPU9150: Clock-based wait_for_sample() impl.
Adapt the I2C driver to a system clock based wait_for_sample()
implementation.

The sample rate of the sensor has been corrected to 800 Hz (could be
further pushed up to 1KHz).

Filters for the mag have also been created but remain commented until
the code for the mag is ready.
2014-07-14 09:10:23 +10:00
Andrew Tridgell ab7e96b9de AP_InertialSensor: updates for ERLE board type 2014-07-14 08:51:44 +10:00
Victor Mayoral Vilches 44320708a7 AP_InertialSensor_MPU9150: I2C userspace driver sensor added.
The MPU9150 is a 9 axis sensor that includes 3 accelerometers,
3 gyroscopes and 3 magnetometers. All accessible through I2C.
The AP_InertialSensor_MPU9150 class allows APM to use this sensor.
2014-07-14 08:16:29 +10:00