Wiki

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
resources:tools-software:linux-drivers:iio-dac:ad5755 [27 Jan 2012 16:40] – Approved Robin Getzresources:tools-software:linux-drivers:iio-dac:ad5755 [05 Jan 2021 16:02] (current) – Removed old references Ioana Chelaru
Line 12: Line 12:
 ===== Reference Circuits ===== ===== Reference Circuits =====
  
-  * [[adi>CN0123]] +  * [[adi>CN0198]] 
-  * [[adi>CN0131]] +  * [[adi>CN0328]]
-  * [[adi>CN0149]]+
  
 ===== Evaluation Boards ===== ===== Evaluation Boards =====
  
   * [[adi>EVAL-AD5755SDZ]]   * [[adi>EVAL-AD5755SDZ]]
 +  * [[adi>EVAL-AD5755-1SDZ]]
 +  * [[adi>EVAL-AD5757SDZ]]
  
 ===== Description ===== ===== Description =====
Line 30: Line 31:
 ===== Status ===== ===== Status =====
  
- Source   Mainlined?  +^ Source ^ Mainlined? ^ 
-| [[bfgit>linux-kernel?drivers/staging/iio/dac/ad5755.c|git]] |  [[git.linux.org>drivers/staging/iio/dac/ad5755.c|Inprogress]]  |+| [[git.linux.org>drivers/iio/dac/ad5755.c|git]] | [[git.linux.org>drivers/iio/dac/ad5755.c|Yes]] |
 ===== Files ===== ===== Files =====
  
 ^ Function ^ File ^ ^ Function ^ File ^
-| driver  | [[git.linux.org>drivers/staging/iio/dac/ad5755.c]] |+| driver  | [[git.linux.org>drivers/iio/dac/ad5755.c]] |
  
 ====== Example platform device initialization ====== ====== Example platform device initialization ======
Line 79: Line 80:
 "make qconfig") "make qconfig")
  
-<note>+<WRAP round help>
 The AD5755 Driver depends on **CONFIG_SPI** The AD5755 Driver depends on **CONFIG_SPI**
-</note>+</WRAP>
  
 <code> <code>
 Linux Kernel Configuration Linux Kernel Configuration
- Device Drivers  ---> +    Device Drivers  ---> 
- [*] Staging drivers  ---> +        ... 
- <*>     Industrial I/O support ---> +        <*>     Industrial I/O support ---> 
-     --- Industrial I/O support +            --- Industrial I/O support 
-     -*-   Enable ring buffer support within IIO +            ... 
-     -*-     Industrial I/O lock free software ring +            Digital to analog converters  --- 
-     -*-   Enable triggered sampling support +                ... 
- +                <*>  Analog Devices AD5755/AD5755-1/AD5757/AD5735/AD5737 DAC driver 
-           *** Digital to analog convertors *** +                ... 
-     [--snip--] +            ... 
- +        ...
-     <*>  Analog Devices Analog Devices AD5755/AD5755-1/AD5757/AD5735/AD5737 DAC driver +
- +
-     [--snip--] +
 </code> </code>
- 
 ====== Hardware configuration ====== ====== Hardware configuration ======
  
Line 109: Line 105:
 {{page>software:linux:docs:iio:iio_snippets#iio device files&noheader&firstseconly&noeditbtn}} {{page>software:linux:docs:iio:iio_snippets#iio device files&noheader&firstseconly&noeditbtn}}
  
-<box 100% green|shell prompt running on the target>+<WRAP box bggreen><wrap info>This specifies any shell prompt running on the target</wrap>
 <xterm> <xterm>
 root:/> **cd /sys/bus/iio/devices/** root:/> **cd /sys/bus/iio/devices/**
Line 148: Line 144:
 lrwxrwxrwx    1 root     root             0 Jan  2 21:54 subsystem -> ../../../../../bus/iio lrwxrwxrwx    1 root     root             0 Jan  2 21:54 subsystem -> ../../../../../bus/iio
 -rw-r--r--    1 root     root          4096 Jan  2 21:54 uevent -rw-r--r--    1 root     root          4096 Jan  2 21:54 uevent
-</xterm></box>+</xterm></WRAP>
  
 === Show device name === === Show device name ===
  
-<box 100% green|shell prompt running on the target>+<WRAP box bggreen><wrap info>This specifies any shell prompt running on the target</wrap>
 <xterm> <xterm>
 root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat name** root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat name**
 ad5755 ad5755
-</xterm></box>+</xterm></WRAP>
  
 === Show scale === === Show scale ===
Line 166: Line 162:
 scale to be applied to out_voltageY_raw/out_currentY_raw in order to obtain the measured voltage in millivolts. scale to be applied to out_voltageY_raw/out_currentY_raw in order to obtain the measured voltage in millivolts.
  
-<box 100% green|shell prompt running on the target>+<WRAP box bggreen><wrap info>This specifies any shell prompt running on the target</wrap>
 <xterm> <xterm>
 root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_voltage2_scale** root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_voltage2_scale**
Line 172: Line 168:
 root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_current0_scale** root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_current0_scale**
 0.000244100 0.000244100
-</xterm></box>+</xterm></WRAP>
  
 === Show offset === === Show offset ===
Line 181: Line 177:
 The offset is applied before scale is applied. The offset is applied before scale is applied.
  
-<box 100% green|shell prompt running on the target>+<WRAP box bggreen><wrap info>This specifies any shell prompt running on the target</wrap>
 <xterm> <xterm>
 root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_voltage2_offset** root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_voltage2_offset**
Line 187: Line 183:
 root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_current0_offset** root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_current0_offset**
 16384 16384
-</xterm></box>+</xterm></WRAP>
  
 === Set channel Y output voltage === === Set channel Y output voltage ===
Line 198: Line 194:
 channel Y. channel Y.
  
-<box 100% green|shell prompt running on the target>+<WRAP box bggreen><wrap info>This specifies any shell prompt running on the target</wrap>
 <xterm> <xterm>
 root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **echo 10000 > out_voltage2_raw** root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **echo 10000 > out_voltage2_raw**
-</xterm></box>+</xterm></WRAP>
  
 **U** = //(out_voltage2_raw + out_voltage2_offset) * out_voltage2_scale// = (10000 - TBD) * 0,038140 //mV// = **TBD //mV//** \\ **U** = //(out_voltage2_raw + out_voltage2_offset) * out_voltage2_scale// = (10000 - TBD) * 0,038140 //mV// = **TBD //mV//** \\
Line 215: Line 211:
 The default value is 65535, minium value is 0, maximum value is 65535. The default value is 65535, minium value is 0, maximum value is 65535.
  
-If scale calibration is used the following formula can be used calculate the output voltage: +If scale calibration is used the following formula can be used calculate the output voltage:
 **U** = //( ( ( out_voltageY_raw + out_voltageY_offset ) * ( out_voltageY_calibscale + 1 ) ) / 2^16 + out_voltageY_calibbias ) *  out_voltageY_scale// **U** = //( ( ( out_voltageY_raw + out_voltageY_offset ) * ( out_voltageY_calibscale + 1 ) ) / 2^16 + out_voltageY_calibbias ) *  out_voltageY_scale//
  
Line 227: Line 223:
 The default value is 0, minium value is -32768, maximum value is 32767. The default value is 0, minium value is -32768, maximum value is 32767.
  
-If offset calibration is used the following formula can be used calculate the output voltage: +If offset calibration is used the following formula can be used calculate the output voltage:
 **U** = //( ( ( out_voltageY_raw + out_voltageY_offset ) * ( out_voltageY_calibscale + 1 ) ) / 2^16 + out_voltageY_calibbias ) *  out_voltageY_scale// **U** = //( ( ( out_voltageY_raw + out_voltageY_offset ) * ( out_voltageY_calibscale + 1 ) ) / 2^16 + out_voltageY_calibbias ) *  out_voltageY_scale//
  
Line 239: Line 235:
 normal operation. normal operation.
  
-<box 100% green|shell prompt running on the target>+<WRAP box bggreen><wrap info>This specifies any shell prompt running on the target</wrap>
 <xterm> <xterm>
 root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **echo 1 > out_voltage2_powerdown** root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **echo 1 > out_voltage2_powerdown**
Line 247: Line 243:
 root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_voltage2_powerdown** root:/sys/devices/platform/bfin-spi.0/spi0.3/iio:device0> **cat out_voltage2_powerdown**
 0 0
-</xterm></box>+</xterm></WRAP>
  
 ====== More Information ====== ====== More Information ======
  
 {{page>software:linux:docs:iio:iio_snippets#iio pointers&noheader&firstseconly&noeditbtn}} {{page>software:linux:docs:iio:iio_snippets#iio pointers&noheader&firstseconly&noeditbtn}}
resources/tools-software/linux-drivers/iio-dac/ad5755.1327678826.txt.gz · Last modified: 27 Jan 2012 16:40 by Robin Getz