Microchip mcp3201 and similar ADCs
Schema identifier ($id): "http://devicetree.org/schemas/iio/adc/microchip,mcp3201.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
Maintainers (maintainers): "Oskar Andero <oskar.andero@gmail.com>"
Family of simple ADCs with a SPI interface.
Properties and child nodes (properties) #
compatible — required here #
Allowed values (enum): "microchip,mcp3001", "microchip,mcp3002", "microchip,mcp3004", "microchip,mcp3008", "microchip,mcp3201", "microchip,mcp3202", "microchip,mcp3204", "microchip,mcp3208", "microchip,mcp3301", "microchip,mcp3550-50", "microchip,mcp3550-60", "microchip,mcp3551", "microchip,mcp3553"
reg — required here #
Maximum number of items (maxItems): 1
spi-cpha — not listed as required here #
true — No constraints added by this property rule.
spi-cpol — not listed as required here #
true — No constraints added by this property rule.
vref-supply — required here #
External reference.
#io-channel-cells — not listed as required here #
Exact value (const): 1
Property dependencies (dependencies) #
spi-cpol — applies when this property is present #
Also requires: "spi-cpha"
spi-cpha — applies when this property is present #
Also requires: "spi-cpol"
Required in this object (required): "compatible", "reg", "vref-supply"
All of these rules must match (allOf) #
Rule 1 #
Shared schema rule (
$ref):/schemas/spi/spi-peripheral-props.yaml#
Properties not evaluated by applicable rules (unevaluatedProperties) #
false
Not allowed by this rule.
Examples (examples) #
spi {
#address-cells = <1>;
#size-cells = <0>;
adc@0 {
compatible = "microchip,mcp3002";
reg = <0>;
vref-supply = <&vref_reg>;
spi-cpha;
spi-cpol;
#io-channel-cells = <1>;
};
adc@1 {
compatible = "microchip,mcp3002";
reg = <1>;
vref-supply = <&vref_reg>;
spi-max-frequency = <1500000>;
};
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)