Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
120 changes: 120 additions & 0 deletions Documentation/devicetree/bindings/iio/dac/adi,max22007.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/iio/dac/adi,max22007.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Analog Devices MAX22007 DAC

maintainers:
- Janani Sunil <janani.sunil@analog.com>

description:
The MAX22007 is a quad-channel, 12-bit digital-to-analog converter (DAC)
with integrated precision output amplifiers and current output capability.
Each channel can be independently configured for voltage or current output.
Datasheet available at https://www.analog.com/en/products/max22007.html

$ref: /schemas/spi/spi-peripheral-props.yaml#

properties:
compatible:
const: adi,max22007

reg:
maxItems: 1

spi-max-frequency:
maximum: 500000

'#address-cells':
const: 1

'#size-cells':
const: 0

vdd-supply:
description: Low-Voltage Power Supply from +2.7V to +5.5V.

hvdd-supply:
description:
Positive High-Voltage Power Supply from +8V to (HVSS +24V) for
the Output Channels.

hvss-supply:
description:
Optional Negative High-Voltage Power Supply from -2V to 0V for the Output
Channels. For most applications HVSS can be connected to GND (0V), but for
applications requiring output down to true 0V or 0mA, connect to a -2V supply.

reset-gpios:
maxItems: 1
description:
Active low GPIO.

patternProperties:
"^channel@[0-3]$":
$ref: /schemas/iio/dac/dac.yaml#
type: object
description:
Represents the external channels which are connected to the DAC.

properties:
reg:
description: Channel number
items:
minimum: 0
maximum: 3

adi,ch-func:
description:
Channel output type. Use CH_FUNC_VOLTAGE_OUTPUT for voltage
output or CH_FUNC_CURRENT_OUTPUT for current output.
$ref: /schemas/types.yaml#/definitions/uint32
enum: [1, 2]

required:
- reg
- adi,ch-func

unevaluatedProperties: false

required:
- compatible
- reg
- vdd-supply
- hvdd-supply

unevaluatedProperties: false

examples:
- |
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/iio/addac/adi,ad74413r.h>

spi {
#address-cells = <1>;
#size-cells = <0>;

dac@0 {
compatible = "adi,max22007";
reg = <0>;
spi-max-frequency = <500000>;
reset-gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
vdd-supply = <&vdd_reg>;
hvdd-supply = <&hvdd_reg>;
#address-cells = <1>;
#size-cells = <0>;

channel@0 {
reg = <0>;
adi,ch-func = <CH_FUNC_VOLTAGE_OUTPUT>;
};

channel@1 {
reg = <1>;
adi,ch-func = <CH_FUNC_CURRENT_OUTPUT>;
};
};
};
...
8 changes: 8 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -1439,6 +1439,14 @@ W: https://ez.analog.com/linux-software-drivers
F: Documentation/devicetree/bindings/iio/dac/adi,ad8460.yaml
F: drivers/iio/dac/ad8460.c

ANALOG DEVICES INC MAX22007 DRIVER
M: Janani Sunil <janani.sunil@analog.com>
L: linux-iio@vger.kernel.org
S: Supported
W: https://ez.analog.com/linux-software-drivers
F: Documentation/devicetree/bindings/iio/dac/adi,max22007.yaml
F: drivers/iio/dac/max22007.c

ANALOG DEVICES INC ADA4250 DRIVER
M: Antoniu Miclaus <antoniu.miclaus@analog.com>
L: linux-iio@vger.kernel.org
Expand Down
1 change: 1 addition & 0 deletions drivers/iio/Kconfig.adi
Original file line number Diff line number Diff line change
Expand Up @@ -216,3 +216,4 @@ config IIO_ALL_ADI_DRIVERS
imply LTC2309
imply AD7091R8
imply AD9739A
imply MAX22007
13 changes: 13 additions & 0 deletions drivers/iio/dac/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -472,6 +472,19 @@ config MAX517
This driver can also be built as a module. If so, the module
will be called max517.

config MAX22007
tristate "Analog Devices MAX22007 DAC Driver"
depends on SPI
select REGMAP_SPI
select CRC8
help
Say Y here if you want to build a driver for Analog Devices MAX22007.

MAX22007 is a quad-channel, 12-bit, voltage-output digital to
analog converter (DAC) with SPI interface.

If compiled as a module, it will be called max22007.

config MAX5522
tristate "Maxim MAX5522 DAC driver"
depends on SPI_MASTER
Expand Down
1 change: 1 addition & 0 deletions drivers/iio/dac/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ obj-$(CONFIG_LTC2664) += ltc2664.o
obj-$(CONFIG_LTC2688) += ltc2688.o
obj-$(CONFIG_M62332) += m62332.o
obj-$(CONFIG_MAX517) += max517.o
obj-$(CONFIG_MAX22007) += max22007.o
obj-$(CONFIG_MAX5522) += max5522.o
obj-$(CONFIG_MAX5821) += max5821.o
obj-$(CONFIG_MCP4725) += mcp4725.o
Expand Down
Loading
Loading