Commit e6d2aaa9 authored by Jonathan Cameron's avatar Jonathan Cameron

dt-bindings: iio: adc: ti,adc0832 yaml conversion.

Simple binding conversion of this SPI ADC binding, with reference
voltage.

Added the optional property #io-channel-cells to allow for
consumers of channels if that makes sense for a given board.
Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: default avatarRob Herring <robh@kernel.org>
Cc: Akinobu Mita <akinobu.mita@gmail.com>
Link: https://lore.kernel.org/r/20200809111753.156236-7-jic23@kernel.org
parent cee4a593
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/iio/adc/ti,adc0832.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Texas Instruments ADC0832 and similar ADCs
maintainers:
- Akinobu Mita <akinobu.mita@gmail.com>
description: |
8 bit ADCs with 1, 2, 4 or 8 inputs for single ended or differential
conversion.
properties:
compatible:
enum:
- ti,adc0831
- ti,adc0832
- ti,adc0834
- ti,adc0838
reg:
maxItems: 1
spi-max-frequency: true
vref-supply:
description: External reference, needed to establish input scaling
"#io-channel-cells":
const: 1
required:
- compatible
- reg
- vref-supply
additionalProperties: false
examples:
- |
spi {
#address-cells = <1>;
#size-cells = <0>;
adc@0 {
compatible = "ti,adc0832";
reg = <0>;
vref-supply = <&vdd_supply>;
spi-max-frequency = <200000>;
#io-channel-cells = <1>;
};
};
...
* Texas Instruments' ADC0831/ADC0832/ADC0832/ADC0838
Required properties:
- compatible: Should be one of
* "ti,adc0831"
* "ti,adc0832"
* "ti,adc0834"
* "ti,adc0838"
- reg: spi chip select number for the device
- vref-supply: The regulator supply for ADC reference voltage
- spi-max-frequency: Max SPI frequency to use (< 400000)
Example:
adc@0 {
compatible = "ti,adc0832";
reg = <0>;
vref-supply = <&vdd_supply>;
spi-max-frequency = <200000>;
};
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment