07-03-2013 11:45 AM
In my current setup I am creating two waveforms and appending a new waveform onto each of them every new case in a case structure. I do this by having a shift register pass the appended waveforms back to the beginning of the case statement so that it may be used to add a new waveform to it. Unfortunatley I cannot post my code.
My problem is that once I have appended one waveform in a case onto the entire waveform I do not need that section again after I write it to the DAQ, but the shift register needs to pass something back to the beginning of the case statement. I have tried having it pass constants, and new waveforms with the desired shape but I continue to get an error: "Number of samples to write must be the same for every channel."
I am confident that the solution is clearing out the shift registers after I write to the DAQ card but every time I try to do this I get the same error. Does anyone know how to do this so I can match the number of samples and not get the error?
Thanks
07-05-2013 02:08 PM
Please post your code or a snap shot of your VIs
07-06-2013 09:34 PM
You could try deleting from the waveform array or inserting into array instead of appending. Hard to say without an example.