ScanImage 2019 : Acquisition Stops Unexpectedly-Frame Data Corrupted


When the horizontal resolution is set to a high value in multi channel mode and the acquisition is started, Matlab issues a warning 

The current acquisition data rate is x MB/s, while the bandwidth of PCIe v1.x is 250MB/s. This might result in data loss.

and the console window shows the message



The reason for this behavior is a bottleneck in the data transfer from the FlexRIO FPGA module to the host computer. The FlexRIO module 7961R features a 1GB/s PXIe interface, however the NI PXIe-1073e chassis has only a system bandwidth of 250MB/s, and cannot transfer data to the host at higher speeds.

The FlexRIO digitizer adapter module produces data at a very high rate (NI5732: 320MB/s, NI5734: 960MB/s). Before this data is sent to the host computer, the FPGA pre-processes and reduces the data. ScanImage has two modes of operation: single channel mode and multi channel mode. In single channel mode, only one channel is streamed to the host, while in multi channel mode four channels are streamed to the host. Even if the digitizer module only supports two channels four channels are transferred, where two channels contain actual frame data, while the two remaining channels are set to zero. The data transfer rate can be calculated with the formula

data rate = resonant scanner frequency * number of channels (1 or 4) * horizontal resolution * 2 bytes/pixel * 2 (in bidirectional mode)

for a scanner with 7910Hz resonant frequency and a resolution of 2048 pixels the resulting data rate is

data rate = 7910 Hz * 4 channels * 2048 pixels/channel * 2 bytes/pixel * 2 = 259 MB/s

which exceeds the 250MB/s link of the the PXIe-1073 chassis. ScanImage detects if an acquisition is started with such a configuration and issues a warning message in the Matlab command window. If data is lost due to this bandwith limitation, ScanImage will issue the error message in the console window and the acquisition will stop.



The bandwidth of the PXI system is a physical limitation that cannot be overcome. The following measures can help reducing the data bandwidth:

  • selection of a smaller horizontal resolution

  • deactivation of multi channel mode (reduces data rate by factor of 4)
  • deactivation of bidirectional mode (reduces data rate by factor of 2)