xref: /freebsd/sys/contrib/device-tree/Bindings/iio/adc/vf610-adc.txt (revision c66ec88fed842fbaad62c30d510644ceb7bd2d71)
1*c66ec88fSEmmanuel VadotFreescale vf610 Analog to Digital Converter bindings
2*c66ec88fSEmmanuel Vadot
3*c66ec88fSEmmanuel VadotThe devicetree bindings are for the new ADC driver written for
4*c66ec88fSEmmanuel Vadotvf610/i.MX6slx and upward SoCs from Freescale.
5*c66ec88fSEmmanuel Vadot
6*c66ec88fSEmmanuel VadotRequired properties:
7*c66ec88fSEmmanuel Vadot- compatible: Should contain "fsl,vf610-adc"
8*c66ec88fSEmmanuel Vadot- reg: Offset and length of the register set for the device
9*c66ec88fSEmmanuel Vadot- interrupts: Should contain the interrupt for the device
10*c66ec88fSEmmanuel Vadot- clocks: The clock is needed by the ADC controller, ADC clock source is ipg clock.
11*c66ec88fSEmmanuel Vadot- clock-names: Must contain "adc", matching entry in the clocks property.
12*c66ec88fSEmmanuel Vadot- vref-supply: The regulator supply ADC reference voltage.
13*c66ec88fSEmmanuel Vadot
14*c66ec88fSEmmanuel VadotRecommended properties:
15*c66ec88fSEmmanuel Vadot- fsl,adck-max-frequency: Maximum frequencies according to datasheets operating
16*c66ec88fSEmmanuel Vadot  requirements. Three values are required, depending on conversion mode:
17*c66ec88fSEmmanuel Vadot  - Frequency in normal mode (ADLPC=0, ADHSC=0)
18*c66ec88fSEmmanuel Vadot  - Frequency in high-speed mode (ADLPC=0, ADHSC=1)
19*c66ec88fSEmmanuel Vadot  - Frequency in low-power mode (ADLPC=1, ADHSC=0)
20*c66ec88fSEmmanuel Vadot- min-sample-time: Minimum sampling time in nanoseconds. This value has
21*c66ec88fSEmmanuel Vadot  to be chosen according to the conversion mode and the connected analog
22*c66ec88fSEmmanuel Vadot  source resistance (R_as) and capacitance (C_as). Refer the datasheet's
23*c66ec88fSEmmanuel Vadot  operating requirements. A safe default across a wide range of R_as and
24*c66ec88fSEmmanuel Vadot  C_as as well as conversion modes is 1000ns.
25*c66ec88fSEmmanuel Vadot
26*c66ec88fSEmmanuel VadotExample:
27*c66ec88fSEmmanuel Vadotadc0: adc@4003b000 {
28*c66ec88fSEmmanuel Vadot	compatible = "fsl,vf610-adc";
29*c66ec88fSEmmanuel Vadot	reg = <0x4003b000 0x1000>;
30*c66ec88fSEmmanuel Vadot	interrupts = <0 53 0x04>;
31*c66ec88fSEmmanuel Vadot	clocks = <&clks VF610_CLK_ADC0>;
32*c66ec88fSEmmanuel Vadot	clock-names = "adc";
33*c66ec88fSEmmanuel Vadot	fsl,adck-max-frequency = <30000000>, <40000000>,
34*c66ec88fSEmmanuel Vadot				<20000000>;
35*c66ec88fSEmmanuel Vadot	vref-supply = <&reg_vcc_3v3_mcu>;
36*c66ec88fSEmmanuel Vadot};
37