This shows you the differences between two versions of the page.
Previous revisionNext revision | |||
— | resources:tools-software:linux-drivers:iio-dac:ad5676 [10 Jan 2019 13:34] – [Supported Devices] Mircea Caprioru | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== AD5676 IIO DAC Linux Driver ====== | ||
+ | |||
+ | ===== Supported Devices ===== | ||
+ | |||
+ | This driver supports the | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | |||
+ | ==== Reference Circuits | ||
+ | * [[adi> | ||
+ | |||
+ | ===== Evaluation Boards ===== | ||
+ | |||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | * [[adi> | ||
+ | |||
+ | ===== Description ===== | ||
+ | |||
+ | This is a Linux industrial I/O ([[software: | ||
+ | The industrial I/O subsystem provides a unified framework for drivers for many different types of converters and sensors using a number of different physical interfaces (i2c, spi, etc). | ||
+ | See [[software: | ||
+ | |||
+ | ====== Source Code ====== | ||
+ | |||
+ | ===== Status ===== | ||
+ | |||
+ | ^ Source ^ Mainlined? ^ | ||
+ | | [[https:// | ||
+ | |||
+ | ===== Files ===== | ||
+ | |||
+ | ^ Function ^ File ^ | ||
+ | | driver | ||
+ | | driver | ||
+ | | driver | ||
+ | | driver | ||
+ | |||
+ | ===== Devicetree ===== | ||
+ | |||
+ | Required devicetree properties for spi devices: | ||
+ | * compatible: Needs to be the name of the device. E.g. " | ||
+ | * reg: The chipselect number used for the device | ||
+ | * spi-max-frequency: | ||
+ | * spi-cpol: Needs to be set for the correct SPI mode | ||
+ | * vcc-supply: Phandle to the fixed regulator | ||
+ | |||
+ | < | ||
+ | adc_vref: fixedregulator@0 { | ||
+ | compatible = " | ||
+ | regulator-name = " | ||
+ | regulator-min-microvolt = < | ||
+ | regulator-max-microvolt = < | ||
+ | regulator-boot-on; | ||
+ | }; | ||
+ | |||
+ | # | ||
+ | # | ||
+ | status = " | ||
+ | |||
+ | ad5676@0 { | ||
+ | compatible = " | ||
+ | reg = <0>; | ||
+ | spi-max-frequency = < | ||
+ | spi-cpha; | ||
+ | vcc-supply = <& | ||
+ | }; | ||
+ | </ | ||
+ | |||
+ | Required devicetree properties for i2c devices: | ||
+ | * compatible: Needs to be the name of the device. E.g. " | ||
+ | * reg: The chipselect number used for the device | ||
+ | * vcc-supply: Phandle to the fixed regulator | ||
+ | |||
+ | < | ||
+ | adc_vref: fixedregulator@0 { | ||
+ | compatible = " | ||
+ | regulator-name = " | ||
+ | regulator-min-microvolt = < | ||
+ | regulator-max-microvolt = < | ||
+ | regulator-boot-on; | ||
+ | }; | ||
+ | |||
+ | # | ||
+ | # | ||
+ | status = " | ||
+ | |||
+ | ad5696@e { | ||
+ | compatible = " | ||
+ | reg = < | ||
+ | vcc-supply = <& | ||
+ | }; | ||
+ | </ | ||
+ | |||
+ | ====== Driver testing ====== | ||
+ | |||
+ | <WRAP box bggreen>< | ||
+ | < | ||
+ | root:/> **cd / | ||
+ | root:/ | ||
+ | iio:device0 | ||
+ | |||
+ | root:/ | ||
+ | |||
+ | root:/ | ||
+ | -r--r--r-- 1 root root 4096 Nov 11 12:03 dev | ||
+ | -r--r--r-- 1 root root 4096 Nov 11 12:03 name | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage0_powerdown | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage0_powerdown_mode | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage0_raw | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage1_powerdown | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage1_powerdown_mode | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage1_raw | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage2_powerdown | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage2_powerdown_mode | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage2_raw | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage3_powerdown | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage3_powerdown_mode | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage3_raw | ||
+ | -r--r--r-- 1 root root 4096 Nov 11 12:03 out_voltage_powerdown_mode_available | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 out_voltage_scale | ||
+ | drwxr-xr-x 2 root root 0 Nov 11 12:03 power | ||
+ | lrwxrwxrwx 1 root root 0 Nov 11 12:03 subsystem -> ../ | ||
+ | -rw-r--r-- 1 root root 4096 Nov 11 12:03 uevent | ||
+ | </ | ||
+ | |||
+ | === Show device name === | ||
+ | |||
+ | <WRAP box bggreen>< | ||
+ | < | ||
+ | root:/ | ||
+ | ad5696 | ||
+ | </ | ||
+ | |||
+ | === Show scale === | ||
+ | |||
+ | **Description: | ||
+ | scale to be applied to in_voltage0_raw in order to obtain the measured voltage in millivolts. | ||
+ | |||
+ | <WRAP box bggreen>< | ||
+ | < | ||
+ | root:/ | ||
+ | 0.038146972 | ||
+ | </ | ||
+ | |||
+ | === Set channel Y output voltage === | ||
+ | |||
+ | **Description: | ||
+ | / | ||
+ | |||
+ | Raw (unscaled, no bias etc.) output voltage for | ||
+ | channel Y. | ||
+ | |||
+ | |||
+ | <WRAP box bggreen>< | ||
+ | < | ||
+ | root:/ | ||
+ | </ | ||
+ | |||
+ | **U** = // | ||
+ | |||
+ | === List available power down modes === | ||
+ | |||
+ | / | ||
+ | |||
+ | **Description: | ||
+ | Lists all available output power down modes. | ||
+ | |||
+ | <WRAP box bggreen>< | ||
+ | < | ||
+ | root:/ | ||
+ | 1kohm_to_gnd 100kohm_to_gnd three_state | ||
+ | </ | ||
+ | |||
+ | === Set channel Y power down mode === | ||
+ | |||
+ | / | ||
+ | |||
+ | **Description: | ||
+ | Specifies the output power down mode. | ||
+ | DAC output stage is disconnected from the amplifier and\\ | ||
+ | |||
+ | | 1kohm_to_gnd | connected to ground via an 1kOhm resistor | | ||
+ | | 100kohm_to_gnd | connected to ground via an 100kOhm resistor | | ||
+ | | three_state | left floating | | ||
+ | |||
+ | For a list of available output power down options read | ||
+ | out_voltageX_powerdown_mode_available. | ||
+ | |||
+ | |||
+ | <WRAP box bggreen>< | ||
+ | < | ||
+ | root:/ | ||
+ | root:/ | ||
+ | three_state | ||
+ | </ | ||
+ | |||
+ | === Enable power down mode on output Y === | ||
+ | |||
+ | / | ||
+ | |||
+ | **Description: | ||
+ | Writing 1 causes output Y to enter the power down mode specified | ||
+ | by the corresponding out_voltageY_powerdown_mode. Clearing returns to | ||
+ | normal operation. Y may be suppressed if all outputs are | ||
+ | controlled together. | ||
+ | |||
+ | <WRAP box bggreen>< | ||
+ | < | ||
+ | root:/ | ||
+ | root:/ | ||
+ | 1 | ||
+ | root:/ | ||
+ | root:/ | ||
+ | 0 | ||
+ | </ | ||
+ | |||
+ | |||
+ | ====== More Information ====== | ||
+ | |||
+ | {{page> | ||