1*ae5de77eSEmmanuel Vadot# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 2*ae5de77eSEmmanuel Vadot%YAML 1.2 3*ae5de77eSEmmanuel Vadot--- 4*ae5de77eSEmmanuel Vadot$id: http://devicetree.org/schemas/iio/adc/rohm,bd79124.yaml# 5*ae5de77eSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6*ae5de77eSEmmanuel Vadot 7*ae5de77eSEmmanuel Vadottitle: ROHM BD79124 ADC/GPO 8*ae5de77eSEmmanuel Vadot 9*ae5de77eSEmmanuel Vadotmaintainers: 10*ae5de77eSEmmanuel Vadot - Matti Vaittinen <mazziesaccount@gmail.com> 11*ae5de77eSEmmanuel Vadot 12*ae5de77eSEmmanuel Vadotdescription: | 13*ae5de77eSEmmanuel Vadot The ROHM BD79124 is a 12-bit, 8-channel, SAR ADC. The ADC supports 14*ae5de77eSEmmanuel Vadot an automatic measurement mode, with an alarm interrupt for out-of-window 15*ae5de77eSEmmanuel Vadot measurements. ADC input pins can be also configured as general purpose 16*ae5de77eSEmmanuel Vadot outputs. 17*ae5de77eSEmmanuel Vadot 18*ae5de77eSEmmanuel Vadotproperties: 19*ae5de77eSEmmanuel Vadot compatible: 20*ae5de77eSEmmanuel Vadot const: rohm,bd79124 21*ae5de77eSEmmanuel Vadot 22*ae5de77eSEmmanuel Vadot reg: 23*ae5de77eSEmmanuel Vadot description: 24*ae5de77eSEmmanuel Vadot I2C slave address. 25*ae5de77eSEmmanuel Vadot maxItems: 1 26*ae5de77eSEmmanuel Vadot 27*ae5de77eSEmmanuel Vadot interrupts: 28*ae5de77eSEmmanuel Vadot maxItems: 1 29*ae5de77eSEmmanuel Vadot 30*ae5de77eSEmmanuel Vadot gpio-controller: true 31*ae5de77eSEmmanuel Vadot 32*ae5de77eSEmmanuel Vadot "#gpio-cells": 33*ae5de77eSEmmanuel Vadot const: 1 34*ae5de77eSEmmanuel Vadot description: 35*ae5de77eSEmmanuel Vadot The pin number. 36*ae5de77eSEmmanuel Vadot 37*ae5de77eSEmmanuel Vadot vdd-supply: true 38*ae5de77eSEmmanuel Vadot 39*ae5de77eSEmmanuel Vadot iovdd-supply: true 40*ae5de77eSEmmanuel Vadot 41*ae5de77eSEmmanuel Vadot "#address-cells": 42*ae5de77eSEmmanuel Vadot const: 1 43*ae5de77eSEmmanuel Vadot 44*ae5de77eSEmmanuel Vadot "#size-cells": 45*ae5de77eSEmmanuel Vadot const: 0 46*ae5de77eSEmmanuel Vadot 47*ae5de77eSEmmanuel VadotpatternProperties: 48*ae5de77eSEmmanuel Vadot "^channel@[0-7]+$": 49*ae5de77eSEmmanuel Vadot type: object 50*ae5de77eSEmmanuel Vadot $ref: /schemas/iio/adc/adc.yaml# 51*ae5de77eSEmmanuel Vadot description: Represents ADC channel. 52*ae5de77eSEmmanuel Vadot 53*ae5de77eSEmmanuel Vadot properties: 54*ae5de77eSEmmanuel Vadot reg: 55*ae5de77eSEmmanuel Vadot description: AIN pin number 56*ae5de77eSEmmanuel Vadot minimum: 0 57*ae5de77eSEmmanuel Vadot maximum: 7 58*ae5de77eSEmmanuel Vadot 59*ae5de77eSEmmanuel Vadot required: 60*ae5de77eSEmmanuel Vadot - reg 61*ae5de77eSEmmanuel Vadot 62*ae5de77eSEmmanuel Vadot additionalProperties: false 63*ae5de77eSEmmanuel Vadot 64*ae5de77eSEmmanuel Vadotrequired: 65*ae5de77eSEmmanuel Vadot - compatible 66*ae5de77eSEmmanuel Vadot - reg 67*ae5de77eSEmmanuel Vadot - iovdd-supply 68*ae5de77eSEmmanuel Vadot - vdd-supply 69*ae5de77eSEmmanuel Vadot 70*ae5de77eSEmmanuel VadotadditionalProperties: false 71*ae5de77eSEmmanuel Vadot 72*ae5de77eSEmmanuel Vadotexamples: 73*ae5de77eSEmmanuel Vadot - | 74*ae5de77eSEmmanuel Vadot #include <dt-bindings/interrupt-controller/irq.h> 75*ae5de77eSEmmanuel Vadot #include <dt-bindings/leds/common.h> 76*ae5de77eSEmmanuel Vadot i2c { 77*ae5de77eSEmmanuel Vadot #address-cells = <1>; 78*ae5de77eSEmmanuel Vadot #size-cells = <0>; 79*ae5de77eSEmmanuel Vadot adc: adc@10 { 80*ae5de77eSEmmanuel Vadot compatible = "rohm,bd79124"; 81*ae5de77eSEmmanuel Vadot reg = <0x10>; 82*ae5de77eSEmmanuel Vadot 83*ae5de77eSEmmanuel Vadot interrupt-parent = <&gpio1>; 84*ae5de77eSEmmanuel Vadot interrupts = <29 8>; 85*ae5de77eSEmmanuel Vadot 86*ae5de77eSEmmanuel Vadot vdd-supply = <&dummyreg>; 87*ae5de77eSEmmanuel Vadot iovdd-supply = <&dummyreg>; 88*ae5de77eSEmmanuel Vadot 89*ae5de77eSEmmanuel Vadot #address-cells = <1>; 90*ae5de77eSEmmanuel Vadot #size-cells = <0>; 91*ae5de77eSEmmanuel Vadot 92*ae5de77eSEmmanuel Vadot channel@0 { 93*ae5de77eSEmmanuel Vadot reg = <0>; 94*ae5de77eSEmmanuel Vadot }; 95*ae5de77eSEmmanuel Vadot channel@1 { 96*ae5de77eSEmmanuel Vadot reg = <1>; 97*ae5de77eSEmmanuel Vadot }; 98*ae5de77eSEmmanuel Vadot channel@2 { 99*ae5de77eSEmmanuel Vadot reg = <2>; 100*ae5de77eSEmmanuel Vadot }; 101*ae5de77eSEmmanuel Vadot channel@3 { 102*ae5de77eSEmmanuel Vadot reg = <3>; 103*ae5de77eSEmmanuel Vadot }; 104*ae5de77eSEmmanuel Vadot channel@4 { 105*ae5de77eSEmmanuel Vadot reg = <4>; 106*ae5de77eSEmmanuel Vadot }; 107*ae5de77eSEmmanuel Vadot channel@5 { 108*ae5de77eSEmmanuel Vadot reg = <5>; 109*ae5de77eSEmmanuel Vadot }; 110*ae5de77eSEmmanuel Vadot channel@6 { 111*ae5de77eSEmmanuel Vadot reg = <6>; 112*ae5de77eSEmmanuel Vadot }; 113*ae5de77eSEmmanuel Vadot }; 114*ae5de77eSEmmanuel Vadot }; 115