Andrew Tridgell
1bb3974c84
l3gd20: check DRDY after check_registers() is called
...
this allows us to recover from an error that disables data ready
2015-01-01 08:51:40 +11:00
Andrew Tridgell
8db2066151
l3gd20: removed printf in interrupt context
...
this is not safe
2015-01-01 08:51:37 +11:00
Andrew Tridgell
353ea9beac
l3gd20: added testerror command
...
useful for testing error handling
2015-01-01 08:51:34 +11:00
Andrew Tridgell
a8cea3a4da
l3gd20: use the I2C disable bit on l3gd20H
...
this seems to prevent a mpu6000 reset from causing an issue on the
l3gd20H
2014-12-30 20:55:57 +01:00
Andrew Tridgell
b455d647b2
l3gd20: added "l3gd20 regdump" command
2014-12-30 20:55:57 +01:00
Andrew Tridgell
ca47952281
l3gd20: added register checking
...
this checks at runtime that key registers have correct values
2014-12-30 20:55:57 +01:00
Lorenz Meier
c600a7fbd2
L3GD20: Fix typo
2014-11-03 15:37:24 +01:00
Lorenz Meier
06df0f23a3
L3GD20: Output gyro temperature in report
2014-11-03 12:56:35 +01:00
Lorenz Meier
c5e4f33bb3
Merge sensor_startup_cleanup
2014-07-16 15:26:22 +02:00
Lorenz Meier
5baa3690e0
L3GD20: Ensure init and constructors
2014-07-16 08:48:10 +02:00
Lorenz Meier
c2f97e628c
L3GD20 driver: stack size adjustments of start handler and start return review / comments
2014-07-16 07:51:47 +02:00
Lorenz Meier
65367f7a99
L3GD20: Support for up to three gyros
2014-07-15 23:16:04 +02:00
Lorenz Meier
e696ed5509
Merged master
2014-07-15 22:07:03 +02:00
Lorenz Meier
812d326912
L3GD20: Fix usage function call to fit existing structure.
2014-07-08 13:52:42 +02:00
Andrew Tridgell
4271634585
l3gd20: fixed a build warning
2014-07-08 12:03:09 +02:00
Andrew Tridgell
a049f0841d
Merged L3GD20 orientation flag while keeping original bus speed
2014-07-08 11:56:45 +02:00
Andrew Tridgell
e7360f4016
l3gd20: added -X switch for external bus
2014-07-08 11:44:06 +02:00
Lorenz Meier
c35a25e70a
L3GD20: Add support for multi uORB topics
2014-06-10 15:08:21 +02:00
Ash Charles
cbc559b6d6
[l3gd20] Make gyro orientation board-overridable
...
As discussed [1], provide a default SENSOR_BOARD_ROTATION
(270 degrees as this seems most common) and let boards override it
as necessary.
[1] 7d0850a710 (commitcomment-6315550)
Signed-off-by: Ash Charles <ashcharles@gmail.com >
2014-05-14 09:19:30 -07:00
Ash Charles
7d0850a710
[l3gd20] Style fixes for l3g4200d integration
...
As requested here [1], this fixes some of the style errors
introduced with the addition of l3g4200d support to the l3gd20
driver. Gyro orientation is set conditionally for the aerocore
board.
[1] https://github.com/PX4/Firmware/pull/937
Signed-off-by: Ash Charles <ashcharles@gmail.com >
2014-05-13 14:00:44 -07:00
Ash Charles
3b72e31e83
[l3gd20] Add support for L3G4200D chip
...
The L3G4200D chip is very similar to the L3GD20[H] parts and can use
the same driver with minor adjustments. There are four differences:
* WHO_AM_I register is 0xD3 (not 0xD4 or 0xD7):
- added an extra case to the driver probe
* Sampling rates are marginally different:
- setting sampling rate now depends on the detected chip
* I2C address range is different:
- no changes as the driver doesn't support i2c access
* the L3G4200D has a self-test function:
- no changes---chose not to implement feature in driver
Signed-off-by: Ash Charles <ashcharles@gmail.com >
2014-05-13 10:01:17 -07:00
Lorenz Meier
d199710651
Fixed up init sequence of all sensors - we can publish in interrupt context, but not advertise! All advertisements now contain valid data
2014-01-14 15:40:46 +01:00
Lorenz Meier
3c7766db6c
Support for publication blocking: L3GD20(H)
2014-01-12 11:54:10 +01:00
Lorenz Meier
f4ac204f46
Cranking up bus speeds for all sensors to achievable 10.4 MHz, will cut the bus lock time to half
2013-12-15 18:32:46 +01:00
Andrew Tridgell
8f90efa312
l3gd20: print more perf counters and make DRDY usage clearer
2013-12-13 11:19:18 +01:00
Andrew Tridgell
17502cbde4
l3gd20: fixed a warning
2013-12-13 11:18:59 +01:00
Andrew Tridgell
893d66d961
l3gd20: added rescheduling and error checking
2013-12-10 11:40:06 +01:00
Andrew Tridgell
1bac7e7f8b
l3gd20: close fds before exit
2013-12-10 11:39:07 +01:00
Andrew Tridgell
5a88dc02a7
l3gd20: use register_class_devname()
2013-12-10 11:38:10 +01:00
Lorenz Meier
eed5b99a4a
Merge branch 'redundant_sensors' of github.com:PX4/Firmware
2013-12-10 11:37:25 +01:00
Andrew Tridgell
86ec1c37fa
l3gd20: added retries to disable_i2c()
2013-12-10 11:03:12 +01:00
Andrew Tridgell
476070510e
lsm303d/l3gd20: change filters to 50Hz analog on-chip filters
...
after discussion with Leonard these analog on-chip filters should be
at 50Hz
2013-12-10 11:02:49 +01:00
Lorenz Meier
7becbcdbd5
Made all usual suspects default to their custom names and only register the default name if its not already taken by someone else
2013-12-07 10:34:32 +01:00
Andrew Tridgell
edc5b68499
l3gd20: use highest possible on-chip filter bandwidth
...
this allows the software filter to do its job properly
2013-12-04 07:08:23 +01:00
Andrew Tridgell
cb76f07d31
l3gd20: added I2C disable based on method from ST engineering support
2013-11-30 20:20:23 +11:00
Lorenz Meier
90c4664dce
Merged status changes
2013-10-06 14:17:37 +02:00
px4dev
19fdaf2009
Use the generic device::SPI locking strategy.
2013-09-12 23:56:53 -07:00
Andrew Tridgell
4893509344
drivers: report error_count in drivers where possible
2013-09-12 09:26:49 +02:00
px4dev
cefc7ac00e
Rework the ringbuffer class so that it's not templated, and refactor its clients so they aren't dancing around the linker anymore.
2013-09-12 00:53:08 +02:00
Andrew Tridgell
63fb702d7f
l3gd20: convert to using RingBuffer class
2013-09-12 00:52:31 +02:00
Lorenz Meier
3a326cb467
Guard probe / reset against other SPI drivers
2013-09-11 22:16:29 +02:00
Andrew Tridgell
fdbc09e2a5
avoid counters going above limit in INCREMENT()
...
when using INCREMENT() the counter would temporarily read equal to
limit, which could cause an issue if the task is preempted.
(this macro should be in a common header, though which header?)
2013-08-28 11:16:30 +02:00
Julian Oes
1ede95d252
L3GD20 and LSM303D reset and range config working properly now
2013-08-21 14:21:54 +02:00
Lorenz Meier
2a58929ffd
Merge branch 'master' of github.com:PX4/Firmware into fmuv2_bringup
2013-08-20 16:26:15 +02:00
Lorenz Meier
05e4c086ce
Added orientation support and detection to the L3GD20/H driver to support the different variants in use
2013-08-16 16:24:44 +02:00
Lorenz Meier
cbb5ce8f59
Fixed startup behavior for PX4 autostart
2013-08-11 16:54:00 +02:00
Lorenz Meier
dccdc977d5
Made accel / gyro self tests aware of offsets and scales, added support to config command to call these
2013-08-09 17:56:32 +02:00
Andrew Tridgell
547a747752
Merged commit disabling FIFO in L3GD20
2013-08-07 15:40:43 +02:00
Lorenz Meier
ca9a11a586
Indendation fixes
2013-08-05 23:09:02 +02:00
Andrew Tridgell
83189a85da
l3gd20: disable the FIFO
...
the FIFO was not gaining us anything, and was adding latency. If we
use the FIFO we'd need to do multiple SPI transfers to ensure it is
drained
2013-08-04 16:13:48 +02:00