2.7 - DAC
The LabJack U3 has 2 analog outputs (DAC0 and DAC1) that are available on the screw terminals. Each analog output can be set to a voltage between about 0.04 and 4.95 volts with 10 bits of resolution (8 bits on older hardware revision 1.20/1.21). The maximum output voltage is limited by the supply voltage to the U3.
Starting with hardware revision 1.30, DAC1 is always enabled and does not affect the analog inputs, but with older hardware the second analog output is only available in certain configurations. With hardware revisions <1.30, if the analog inputs are using the internal 2.4 volt reference (the most accurate option), then DAC1 outputs a fixed voltage of 1.5*Vref. Also with hardware revisions <1.30, if DAC1 is enabled the analog inputs use Vreg (3.3 volts) as the ADC reference, which is not as stable as the internal 2.4 volt reference.
The DAC outputs are derived as a percentage of Vreg, and then amplified by 1.5, so any changes in Vreg will have a proportionate affect on the DAC outputs. Vreg is more stable than Vs (5 volt supply voltage), as it is the output from a 3.3 volt regulator.
The DACs are derived from PWM signals that are affected by the timer clock frequency (Section 2.9). The default timer clock frequency of the U3 is set to 48 MHz, and this results in the minimum DAC output noise. If the frequency is lowered, the DACs will have more noise, where the frequency of the noise is the timer clock frequency divided by 65536. This effect is more exaggerated with the 10-bit DACs on hardware revision 1.30+, compared to the 8-bit DACs on previous hardware revisions. The noise with a timer clock of 48/12/4/1 MHz is roughly 5/20/100/600 mV. If lower noise performance is needed at lower timer clock frequencies, use the power-up default setting in LJControlPanel to force the device to use 8-bit DAC mode (uses the low-level CompatibilityOptions byte documented in Section 5.2.2). A large capacitor (at least 220 uF) from DACn to GND can also be used to reduce noise.
The analog outputs have filters with a 3 dB cutoff around 16 Hz, limiting the frequency of output waveforms to less than that.
The analog output commands are sent as raw binary values (low level functions). For a desired output voltage, the binary value can be approximated as:
Bits(uncalibrated) = (Volts/4.95)*256
For a proper calculation, though, use the calibration values (Slope and Offset) stored in the internal flash on the processor (Section 5.4):
Bits = (Slope * Volts) + Offset
The previous apply when using the original 8-bit DAC commands supported on all hardware versions. To take advantage of the 10-bit resolution on hardware revision 1.30, new commands have been added (Section 5.2.5) where the binary values are aligned to 16-bits. The cal constants are still aligned to 8-bits, however, so the slope and offset should each be multiplied by 256 before using in the above formula.
The analog outputs can withstand a continuous short-circuit to ground, even when set at maximum output.
Voltage should never be applied to the analog outputs, as they are voltage sources themselves. In the event that a voltage is accidentally applied to either analog output, they do have protection against transient events such as ESD (electrostatic discharge) and continuous overvoltage (or undervoltage) of a few volts.
There is an accessory available from LabJack called the LJTick-DAC that provides a pair of 14-bit analog outputs with a range of ±10 volts. The LJTick-DAC plugs into any digital I/O block, and thus up to 10 of these can be used per U3 to add 20 analog outputs. The LJTick-DAC has various improvements compared to the built-in DACs on the U3:
- Range of +10.0 to -10.0 volts.
- Resolution of 14-bits.
- Slew rate of 0.1 V/μs.
- Based on a reference, rather than regulator, so more accurate and stable.
- Does not affect analog inputs in any configuration.
- UD Series (U3, U6, UE9)
- User's Guide
- 1 - Installation on Windows
- 2 - Hardware Description
- 3 - Operation
- 4 - LabJackUD High-Level Driver
- 5 - Low-level Function Reference
- Appendix A - Specifications
- Appendix B - Enclosure and PCB Drawings
- U3 Firmware Revision History
- User's Guide
- Digit Series
- T Series
I'd like to compliment you on your nicely-written native LabVIEW
drivers; we're customising them to our own ends, but they're a nice
neat starting point—unlike a lot of other people's code! [...] By the
way—excellent table of contents in the PDF Manual—why can't everyone
do that?! [...] Very much enjoying working with the LabJacks—and
looking forward to using them for other jobs.—Tom, CPP Wind Engineering