2012-05-11 15:35:37 +02:00
* AT91's Analog to Digital Converter (ADC)
Required properties:
2013-08-27 12:28:00 +01:00
- compatible: Should be "atmel,<chip>-adc"
<chip> can be "at91sam9260", "at91sam9g45" or "at91sam9x5"
2012-05-11 15:35:37 +02:00
- reg: Should contain ADC registers location and length
- interrupts: Should contain the IRQ line for the ADC
2013-12-17 16:16:00 +00:00
- clock-names: tuple listing input clock names.
Required elements: "adc_clk", "adc_op_clk".
- clocks: phandles to input clocks.
2014-03-10 20:17:18 +01:00
- atmel,adc-channels-used: Bitmask of the channels muxed and enabled for this
2012-05-11 15:35:37 +02:00
device
- atmel,adc-startup-time: Startup Time of the ADC in microseconds as
defined in the datasheet
- atmel,adc-vref: Reference voltage in millivolts for the conversions
2014-03-10 20:17:18 +01:00
- atmel,adc-res: List of resolutions in bits supported by the ADC. List size
2013-03-29 14:54:00 +00:00
must be two at least.
- atmel,adc-res-names: Contains one identifier string for each resolution
in atmel,adc-res property. "lowres" and "highres"
identifiers are required.
2012-05-11 15:35:37 +02:00
Optional properties:
2014-03-10 20:17:18 +01:00
- atmel,adc-use-external-triggers: Boolean to enable the external triggers
2013-03-29 14:54:00 +00:00
- atmel,adc-use-res: String corresponding to an identifier from
atmel,adc-res-names property. If not specified, the highest
resolution will be used.
2013-03-29 14:54:00 +00:00
- atmel,adc-sleep-mode: Boolean to enable sleep mode when no conversion
2013-03-29 14:54:00 +00:00
- atmel,adc-sample-hold-time: Sample and Hold Time in microseconds
2014-03-10 20:17:18 +01:00
- atmel,adc-ts-wires: Number of touchscreen wires. Should be 4 or 5. If this
value is set, then the adc driver will enable touchscreen
2013-10-08 04:48:00 +01:00
support.
2014-03-10 20:17:18 +01:00
NOTE: when adc touchscreen is enabled, the adc hardware trigger will be
disabled. Since touchscreen will occupy the trigger register.
2013-10-08 04:48:00 +01:00
- atmel,adc-ts-pressure-threshold: a pressure threshold for touchscreen. It
2014-03-10 20:17:18 +01:00
makes touch detection more precise.
2012-05-11 15:35:37 +02:00
Optional trigger Nodes:
- Required properties:
* trigger-name: Name of the trigger exposed to the user
* trigger-value: Value to put in the Trigger register
to activate this trigger
- Optional properties:
* trigger-external: Is the trigger an external trigger?
Examples:
adc0: adc@fffb0000 {
2014-03-10 20:17:18 +01:00
#address-cells = <1>;
#size-cells = <0>;
2012-05-11 15:35:37 +02:00
compatible = "atmel,at91sam9260-adc";
reg = <0xfffb0000 0x100>;
2014-03-10 20:17:18 +01:00
interrupts = <20 IRQ_TYPE_LEVEL_HIGH 0>;
2013-12-17 16:16:00 +00:00
clocks = <&adc_clk>, <&adc_op_clk>;
clock-names = "adc_clk", "adc_op_clk";
2012-05-11 15:35:37 +02:00
atmel,adc-channels-used = <0xff>;
atmel,adc-startup-time = <40>;
2014-03-10 20:17:18 +01:00
atmel,adc-use-external-triggers;
2012-05-11 15:35:37 +02:00
atmel,adc-vref = <3300>;
2013-03-29 14:54:00 +00:00
atmel,adc-res = <8 10>;
atmel,adc-res-names = "lowres", "highres";
atmel,adc-use-res = "lowres";
2012-05-11 15:35:37 +02:00
2016-07-12 22:07:59 +02:00
trigger0 {
2012-05-11 15:35:37 +02:00
trigger-name = "external-rising";
trigger-value = <0x1>;
trigger-external;
};
2016-07-12 22:07:59 +02:00
trigger1 {
2012-05-11 15:35:37 +02:00
trigger-name = "external-falling";
trigger-value = <0x2>;
trigger-external;
};
2016-07-12 22:07:59 +02:00
trigger2 {
2012-05-11 15:35:37 +02:00
trigger-name = "external-any";
trigger-value = <0x3>;
trigger-external;
};
2016-07-12 22:07:59 +02:00
trigger3 {
2012-05-11 15:35:37 +02:00
trigger-name = "continuous";
trigger-value = <0x6>;
};
};