Example: ADC burst
This example shows how to read the analog inputs of the ZSOM-Control and the ZSOM-Mini in bursts.
Project: ZSOM-Control_ADC_burst.lvproj (ZSOM-Control) and ZSOM-Mini_ADC_burst.lvproj (ZSOM-Mini). In LabVIEW, open Help → Find Examples and search for “ZSOM”.
The example reads the ADC channels in bursts (blocks of samples) and displays them in a waveform graph. Its function is similar to an oscilloscope. On the ZSOM-Control it reads the six channels of group 1 (AIN1–AIN6). Group 2 is independent and can be read in the same way. On the ZSOM-Mini it reads all six channels.
Front panel
| Control | Function |
|---|---|
| desired sampling frequency | Sampling rate in Hz (default 250000) |
| samples per burst | Block length (default 400, maximum 4096) |
| Range | Input range of the group, see Analog Input |
| start next | Starts the next burst |
| Indicator | Function |
|---|---|
| Waveform Graph | The six channels of the last burst |
| AIN1 – AIN6 | Filtered DC value: mean over 10 bursts |
| achieved sampling frequency | Actual sampling rate, derived from the FPGA loop time |
| ms per burst | Duration of one burst |
| losses between bursts | Number of lost samples between the bursts |
How it works
- FPGA (
ADC_burst_FPGA_main.vi): Samples all six channels simultaneously, uses pipelining for faster loop times and sends the data through a FIFO to the RT. The loop time is derived from the FPGA clock (40 MHz) and the desired sampling frequency. It is measured to calculate the achieved sampling frequency. - RT (
ADC_burst_RT_main.vi): Loads and starts the FPGA, prepares the FIFOs, reads the bursts, displays the result and calculates the filtered DC value.
If the sampling rate is set too high, the RT code can no longer process the data and samples between the bursts are lost. The indicator losses between bursts shows this.


