19.2 Configure the Desired Output Range

Helios features programmable D/A output ranges. You can set one range for all 4 channels or set individual output ranges for each channel. The output range is set with register bits DAPOL and DAG1-0. See the table in section 18.3 on page 40 to select the bit values needed for the desired output range.

To set all 4 channels to the same output range, simply write the desired values of DAPOL and DAG1-0 to the register at page 2 base+14, leaving all other bits at 0. To set an individual range, set DAUR=1 and select the channel with DAGCH1-0 in this register at the same time as you write the DAPOL and DAG1-0 bits.

To set all channels to the same output range:

outp(base+1, 2); // select page 2

outp(base+14, (DAPOL << 3) + gain); // gain = 0, 1, 2, or 3 as appropriate

To set a channel to a unique output range:

outp(base+1, 2); // select page 2

value = 0x80 + (DACH << 4) + (DAPOL << 3) + gain; // DACH = D/A channel 0-3

outp(base+14, value); // sets individual D/A channel to desired range

Last updated