-
Notifications
You must be signed in to change notification settings - Fork 943
Ad5529r driver #3234
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
jansunil
wants to merge
2
commits into
mirror_ci/jic23/iio/testing
Choose a base branch
from
ad5529r-driver
base: mirror_ci/jic23/iio/testing
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Ad5529r driver #3234
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
202 changes: 202 additions & 0 deletions
202
Documentation/devicetree/bindings/iio/dac/adi,ad5529r.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,202 @@ | ||
| # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) | ||
| %YAML 1.2 | ||
| --- | ||
| $id: http://devicetree.org/schemas/iio/dac/adi,ad5529r.yaml# | ||
| $schema: http://devicetree.org/meta-schemas/core.yaml# | ||
|
|
||
| title: Analog Devices AD5529R 16-Channel 12/16-bit High Voltage DAC | ||
|
|
||
| maintainers: | ||
| - Janani Sunil <janani.sunil@analog.com> | ||
|
|
||
| description: | | ||
| The AD5529R is a 16-channel, 12-bit or 16-bit, high voltage, buffered voltage output | ||
| digital-to-analog converter (DAC) with an integrated precision reference. | ||
| The device operates from unipolar and bipolar supplies. It is guaranteed | ||
| monotonic and has built-in rail-to-rail output buffers that can source or | ||
| sink up to 25mA. | ||
|
|
||
| Specifications: | ||
| * 16 independent 12-bit or 16-bit DAC channels | ||
| * Independently programmable output ranges: 0V to 5V, 0V to 10V, 0V to 20V, | ||
| 0V to 40V, ±5V, ±10V, ±15V, and ±20V | ||
| * The device supports SPI communication with Mode 0 and Mode 3. | ||
| * 4.096V precision reference, 12ppm/°C maximum | ||
| * Built-in function generation: Toggle, Sinusoidal Dither, and Ramp waveforms | ||
| * Multiplexer for output voltage, load current sense and die temperature | ||
|
|
||
| Datasheet: https://www.analog.com/media/en/technical-documentation/data-sheets/ad5529r.pdf | ||
|
|
||
| properties: | ||
| compatible: | ||
| enum: | ||
| - adi,ad5529r-16 # 16-bit variant | ||
| - adi,ad5529r-12 # 12-bit variant | ||
|
|
||
| reg: | ||
| maxItems: 1 | ||
|
|
||
| spi-max-frequency: | ||
| maximum: 50000000 | ||
|
|
||
| reset-gpios: | ||
| maxItems: 1 | ||
| description: | ||
| GPIO connected to the RESET pin. Active low. When asserted low, | ||
| performs a power-on reset and initializes the device to its default state. | ||
|
|
||
| clear-gpios: | ||
| maxItems: 1 | ||
| description: | ||
| GPIO connected to the CLEAR pin. Active low. When asserted low, | ||
| clears all DAC data registers without affecting configuration settings. | ||
|
|
||
| interrupts: | ||
| maxItems: 1 | ||
| description: | ||
| Interrupt connected to the ALARM pin. Active low interrupt output | ||
| for overtemperature conditions, SPI CRC errors, and function completion. | ||
|
|
||
| tg1-gpios: | ||
| maxItems: 1 | ||
| description: | ||
| GPIO connected to the TG1 toggle pin. Pulsing this pin allows all | ||
| selected DACs to be updated synchronously for coordinated output changes. | ||
|
|
||
| tg2-gpios: | ||
| maxItems: 1 | ||
| description: | ||
| GPIO connected to the TG2 toggle pin. Pulsing this pin allows all | ||
| selected DACs to be updated synchronously for coordinated output changes. | ||
|
|
||
| tg3-gpios: | ||
| maxItems: 1 | ||
| description: | ||
| GPIO connected to the TG3 toggle pin. Pulsing this pin allows all | ||
| selected DACs to be updated synchronously for coordinated output changes. | ||
|
|
||
| io-channels: | ||
| maxItems: 1 | ||
| description: | ||
| ADC channel connected to the MUXOUT pin for monitoring output voltage, | ||
| load current sense, and die temperature. | ||
|
|
||
| io-channel-names: | ||
| const: muxout | ||
|
|
||
| vdd-supply: | ||
| description: Digital power supply (typically 3.3V) | ||
|
|
||
| avdd-supply: | ||
| description: Analog power supply (typically 5V) | ||
|
|
||
| hvdd-supply: | ||
| description: | ||
| High voltage positive supply. Supply voltage should be chosen | ||
| based on configured output ranges (see datasheet Table 9). | ||
|
|
||
| hvss-supply: | ||
| description: | ||
| High voltage negative supply. Required only when using bipolar | ||
| output ranges (±5V, ±10V, ±15V, ±20V). Supply voltage should be | ||
| chosen based on configured output ranges (see datasheet Table 9). | ||
|
|
||
| "#address-cells": | ||
| const: 1 | ||
|
|
||
| "#size-cells": | ||
| const: 0 | ||
|
|
||
| patternProperties: | ||
| "^channel@([0-9]|1[0-5])$": | ||
| type: object | ||
| description: Child nodes for individual channel configuration | ||
|
|
||
| properties: | ||
| reg: | ||
| description: Channel number. | ||
| minimum: 0 | ||
| maximum: 15 | ||
|
|
||
| adi,output-range-microvolt: | ||
| description: | | ||
| Output voltage range for this channel as [min, max] in microvolts. | ||
| If not specified, defaults to 0V to 5V range. | ||
| oneOf: | ||
| - items: | ||
| - const: 0 | ||
| - enum: [5000000, 10000000, 20000000, 40000000] | ||
| - items: | ||
| - const: -5000000 | ||
| - const: 5000000 | ||
| - items: | ||
| - const: -10000000 | ||
| - const: 10000000 | ||
| - items: | ||
| - const: -15000000 | ||
| - const: 15000000 | ||
| - items: | ||
| - const: -20000000 | ||
| - const: 20000000 | ||
|
|
||
| required: | ||
| - reg | ||
|
|
||
| additionalProperties: false | ||
|
|
||
| required: | ||
| - compatible | ||
| - reg | ||
| - vdd-supply | ||
| - avdd-supply | ||
| - hvdd-supply | ||
|
|
||
| dependencies: | ||
| spi-cpha: [ spi-cpol ] | ||
| spi-cpol: [ spi-cpha ] | ||
|
|
||
| allOf: | ||
| - $ref: /schemas/spi/spi-peripheral-props.yaml# | ||
|
|
||
| unevaluatedProperties: false | ||
|
|
||
| examples: | ||
| - | | ||
| #include <dt-bindings/gpio/gpio.h> | ||
|
|
||
| spi { | ||
| #address-cells = <1>; | ||
| #size-cells = <0>; | ||
|
|
||
| dac@0 { | ||
| compatible = "adi,ad5529r-16"; | ||
| reg = <0>; | ||
| spi-max-frequency = <25000000>; | ||
|
|
||
| vdd-supply = <&vdd_regulator>; | ||
| avdd-supply = <&avdd_regulator>; | ||
| hvdd-supply = <&hvdd_regulator>; | ||
| hvss-supply = <&hvss_regulator>; | ||
|
|
||
| reset-gpios = <&gpio0 87 GPIO_ACTIVE_LOW>; | ||
|
|
||
| #address-cells = <1>; | ||
| #size-cells = <0>; | ||
|
|
||
| channel@0 { | ||
| reg = <0>; | ||
| adi,output-range-microvolt = <0 5000000>; | ||
| }; | ||
|
|
||
| channel@1 { | ||
| reg = <1>; | ||
| adi,output-range-microvolt = <(-10000000) 10000000>; | ||
| }; | ||
|
|
||
| channel@2 { | ||
| reg = <2>; | ||
| adi,output-range-microvolt = <0 40000000>; | ||
| }; | ||
| }; | ||
| }; | ||
| ... | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.