1# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 2%YAML 1.2 3--- 4$id: http://devicetree.org/schemas/iio/imu/invensense,mpu6050.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: InvenSense MPU-6050 Six-Axis (Gyro + Accelerometer) MEMS MotionTracking Device 8 9maintainers: 10 - Jean-Baptiste Maneyrol <jean-baptiste.maneyrol@tdk.com> 11 12description: | 13 These devices support both I2C and SPI bus interfaces. 14 15properties: 16 compatible: 17 oneOf: 18 - enum: 19 - invensense,iam20680 20 - invensense,icm20608 21 - invensense,icm20609 22 - invensense,icm20689 23 - invensense,icm20602 24 - invensense,icm20690 25 - invensense,mpu6000 26 - invensense,mpu6050 27 - invensense,mpu6500 28 - invensense,mpu6515 29 - invensense,mpu6880 30 - invensense,mpu9150 31 - invensense,mpu9250 32 - invensense,mpu9255 33 - items: 34 - const: invensense,icm20600 35 - const: invensense,icm20602 36 - items: 37 - const: invensense,icm20608d 38 - const: invensense,icm20608 39 - items: 40 - enum: 41 - invensense,iam20680hp 42 - invensense,iam20680ht 43 - const: invensense,iam20680 44 45 reg: 46 maxItems: 1 47 48 interrupts: 49 maxItems: 1 50 51 vdd-supply: true 52 vddio-supply: true 53 54 mount-matrix: true 55 56 invensense,level-shifter: 57 type: boolean 58 description: | 59 From ancient platform data struct: false: VLogic, true: VDD 60 61 i2c-gate: 62 $ref: /schemas/i2c/i2c-controller.yaml 63 unevaluatedProperties: false 64 description: | 65 These devices also support an auxiliary i2c bus via an i2c-gate. 66 67allOf: 68 - $ref: /schemas/spi/spi-peripheral-props.yaml# 69 - if: 70 properties: 71 compatible: 72 contains: 73 enum: 74 - invensense,iam20680 75 - invensense,icm20602 76 - invensense,icm20608 77 - invensense,icm20609 78 - invensense,icm20689 79 then: 80 properties: 81 i2c-gate: false 82 83unevaluatedProperties: false 84 85required: 86 - compatible 87 - reg 88 - interrupts 89 90examples: 91 - | 92 #include <dt-bindings/interrupt-controller/irq.h> 93 i2c { 94 #address-cells = <1>; 95 #size-cells = <0>; 96 97 imu@68 { 98 compatible = "invensense,mpu9250"; 99 reg = <0x68>; 100 interrupt-parent = <&gpio3>; 101 interrupts = <21 IRQ_TYPE_LEVEL_HIGH>; 102 mount-matrix = "-0.984807753012208", /* x0 */ 103 "0", /* y0 */ 104 "-0.173648177666930", /* z0 */ 105 "0", /* x1 */ 106 "-1", /* y1 */ 107 "0", /* z1 */ 108 "-0.173648177666930", /* x2 */ 109 "0", /* y2 */ 110 "0.984807753012208"; /* z2 */ 111 i2c-gate { 112 #address-cells = <1>; 113 #size-cells = <0>; 114 magnetometer@c { 115 compatible = "asahi-kasei,ak8975"; 116 reg = <0x0c>; 117 }; 118 }; 119 }; 120 }; 121... 122