diff options
author | Gregor Boirie <gregor.boirie@parrot.com> | 2016-04-20 19:23:45 +0200 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2016-04-23 23:16:01 +0200 |
commit | eb3798463f71afc77abd25b2f62708be06f7173b (patch) | |
tree | d35a30863782850b30e888b9cbc5822386beee1f /Documentation/devicetree/bindings/iio | |
parent | iio:ak8975: add mounting matrix support (diff) | |
download | linux-eb3798463f71afc77abd25b2f62708be06f7173b.tar.xz linux-eb3798463f71afc77abd25b2f62708be06f7173b.zip |
iio:imu:mpu6050: enhance mounting matrix support
Add a new rotation matrix sysfs attribute compliant with IIO core
mounting matrix API.
Matrix is retrieved from "in_anglvel_mount_matrix" and
"in_accel_mount_matrix" sysfs attributes. It is declared into mpu6050 DTS
entry as a "mount-matrix" property.
Old interface is kept for backward userspace compatibility and may be
retrieved from legacy platform_data mechanism only.
Signed-off-by: Gregor Boirie <gregor.boirie@parrot.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'Documentation/devicetree/bindings/iio')
-rw-r--r-- | Documentation/devicetree/bindings/iio/imu/inv_mpu6050.txt | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/Documentation/devicetree/bindings/iio/imu/inv_mpu6050.txt b/Documentation/devicetree/bindings/iio/imu/inv_mpu6050.txt index e4d8f1c52f4a..a9fc11e43b45 100644 --- a/Documentation/devicetree/bindings/iio/imu/inv_mpu6050.txt +++ b/Documentation/devicetree/bindings/iio/imu/inv_mpu6050.txt @@ -8,10 +8,23 @@ Required properties: - interrupt-parent : should be the phandle for the interrupt controller - interrupts : interrupt mapping for GPIO IRQ +Optional properties: + - mount-matrix: an optional 3x3 mounting rotation matrix + + Example: mpu6050@68 { compatible = "invensense,mpu6050"; reg = <0x68>; interrupt-parent = <&gpio1>; interrupts = <18 1>; + mount-matrix = "-0.984807753012208", /* x0 */ + "0", /* y0 */ + "-0.173648177666930", /* z0 */ + "0", /* x1 */ + "-1", /* y1 */ + "0", /* z1 */ + "-0.173648177666930", /* x2 */ + "0", /* y2 */ + "0.984807753012208"; /* z2 */ }; |