NI 5412/5421/5422/5441/5442
Memory Fragmentation
When storing multiple waveforms in NI 5412/5421/5422/5441/5442 memory, fragmentation can become a problem. Both waveforms and instructions are stored in NI 5412/5421/5422/5441/5442 memory in contiguous blocks. These blocks are allocated in multiples of 128 bytes, and they are written in the order that you configure them. Fragmentation occurs when you delete a waveform or script from memory that was not the last block written.
Every new NI-FGEN session begins with empty memory. First, multiple waveforms are written to memory, nearly filling the device memory, as shown in the following diagram.
If you now try to write Waveform 5 (pictured in the following figure) to the device, you find there is not enough memory. To make room for the waveform, you could delete waveform 3 to create enough space in memory for Waveform 5.
Unfortunately, though you now have enough free memory space for Waveform 5, this space is fragmented, so you must also clear and re-download all waveforms and generation instructions following the deleted waveform. The following figure illustrates the result.