OSC_DSP_Waveform_Construct(...) is fixed.

New variables called logical indexes are used to reorder the data
memory in the order of data acquisition. These logical indexes are
used to decide if the given index is the part of the data acquisition
memory.