0001 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/iio/adc/renesas,rcar-gyroadc.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006
0007 title: Renesas R-Car GyroADC
0008
0009 maintainers:
0010 - Marek Vasut <marek.vasut+renesas@gmail.com>
0011
0012 description: |
0013 The GyroADC block is a reduced SPI block with up to 8 chipselect lines,
0014 which supports the SPI protocol of a selected few SPI ADCs. The SPI ADCs
0015 are sampled by the GyroADC block in a round-robin fashion and the result
0016 presented in the GyroADC registers.
0017 The ADC bindings should match with that of the devices connected to a
0018 full featured SPI bus.
0019
0020 properties:
0021 compatible:
0022 items:
0023 - enum:
0024 - renesas,r8a7791-gyroadc
0025 - renesas,r8a7792-gyroadc
0026 - const: renesas,rcar-gyroadc
0027
0028 reg:
0029 maxItems: 1
0030
0031 clocks:
0032 maxItems: 1
0033
0034 clock-names:
0035 const: fck
0036
0037 power-domains: true
0038
0039 resets: true
0040
0041 "#address-cells":
0042 const: 1
0043
0044 "#size-cells":
0045 const: 0
0046
0047 additionalProperties: false
0048
0049 required:
0050 - compatible
0051 - reg
0052 - clocks
0053 - clock-names
0054 - "#address-cells"
0055 - "#size-cells"
0056
0057 patternProperties:
0058 "@[0-7]$":
0059 type: object
0060 properties:
0061 compatible:
0062 description: |
0063 fujitsu,mb88101a
0064 - Fujitsu MB88101A compatible mode,
0065 12bit sampling, up to 4 channels can be sampled in round-robin
0066 fashion. One Fujitsu chip supplies four GyroADC channels with
0067 data as it contains four ADCs on the chip and thus for 4-channel
0068 operation, single MB88101A is required. The Cx chipselect lines
0069 of the MB88101A connect directly to two CHS lines of the GyroADC,
0070 no demuxer is required. The data out line of each MB88101A
0071 connects to a shared input pin of the GyroADC.
0072 ti,adcs7476 or ti,adc121 or adi,ad7476
0073 - TI ADCS7476 / TI ADC121 / ADI AD7476 compatible mode, 15bit
0074 sampling, up to 8 channels can be sampled in round-robin
0075 fashion. One TI/ADI chip supplies single ADC channel with data,
0076 thus for 8-channel operation, 8 chips are required.
0077 A 3:8 chipselect demuxer is required to connect the nCS line
0078 of the TI/ADI chips to the GyroADC, while MISO line of each
0079 TI/ADI ADC connects to a shared input pin of the GyroADC.
0080 maxim,max1162 or maxim,max11100
0081 - Maxim MAX1162 / Maxim MAX11100 compatible mode, 16bit sampling,
0082 up to 8 channels can be sampled in round-robin fashion. One
0083 Maxim chip supplies single ADC channel with data, thus for
0084 8-channel operation, 8 chips are required.
0085 A 3:8 chipselect demuxer is required to connect the nCS line
0086 of the MAX chips to the GyroADC, while MISO line of each Maxim
0087 ADC connects to a shared input pin of the GyroADC.
0088 enum:
0089 - adi,7476
0090 - fujitsu,mb88101a
0091 - maxim,max1162
0092 - maxim,max11100
0093 - ti,adcs7476
0094 - ti,adc121
0095
0096 reg:
0097 minimum: 0
0098 maximum: 7
0099
0100 vref-supply: true
0101
0102 additionalProperties: false
0103
0104 required:
0105 - compatible
0106 - reg
0107 - vref-supply
0108
0109 examples:
0110 - |
0111 #include <dt-bindings/clock/r8a7791-clock.h>
0112 #include <dt-bindings/power/r8a7791-sysc.h>
0113 soc {
0114 #address-cells = <2>;
0115 #size-cells = <2>;
0116
0117 adc@e6e54000 {
0118 compatible = "renesas,r8a7791-gyroadc", "renesas,rcar-gyroadc";
0119 reg = <0 0xe6e54000 0 64>;
0120 clocks = <&mstp9_clks R8A7791_CLK_GYROADC>;
0121 clock-names = "fck";
0122 power-domains = <&sysc R8A7791_PD_ALWAYS_ON>;
0123
0124 pinctrl-0 = <&adc_pins>;
0125 pinctrl-names = "default";
0126
0127 #address-cells = <1>;
0128 #size-cells = <0>;
0129
0130 adc@0 {
0131 reg = <0>;
0132 compatible = "maxim,max1162";
0133 vref-supply = <&vref_max1162>;
0134 };
0135
0136 adc@1 {
0137 reg = <1>;
0138 compatible = "maxim,max1162";
0139 vref-supply = <&vref_max1162>;
0140 };
0141 };
0142 };
0143 ...