14.7 Setup D/A wave form settings

D/A waveform settings include input source, number of code per frame, and threshold. Each can be set individually and in any combination.

There are four different input sources to choose from: manual/software trigger, counter 0 output, counters 1+2 output, and external trigger. Manual trigger should be used when the rate is slow or inconsistent and needs be controlled in software. Counter 0 output should be used when a consistent rate is desired and counter 1/2 is used for A/D interrupts. Counter 1+2 should be used when a consistent rate is desired and counter 0 is used for other interrupt functions, or if you want to synchronize the waveform generator to A/D interrupt functionality. External trigger should be used when an external signal is desired to generate D/A waveform. Input source is set by bits 0 and 1 on Page 5, Base + 14.

Number of code per frame determines the number of buffer values that will be output per frame. Each code is determined by the value set at its address.

For example, if the codes per frame option is set at 2, the first frame will output the codes at address 0 and 1, then 2 and 3, then 4 and 5 and so on. Number of code per frame is set by bits 2 and 3 on Page 5, Base + 14.

Threshold determines the number of code to output before the pointer starts over. The threshold must be set in multiples of 64 up to 1024. When the threshold is hit the pointer wraps around and start at the beginning. Threshold is set by bits 4, 5, 6, and 7 at Page 5, Base + 14.

Last updated