LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

New value for waveform in shift register

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

0 Kudos
Message 1 of 3
(2,408 Views)

Please post your code or a snap shot of your VIs Smiley Wink

0 Kudos
Message 2 of 3
(2,378 Views)

You could try deleting from the waveform array or inserting into array instead of appending. Hard to say without an example.

CLD Certified 2014
0 Kudos
Message 3 of 3
(2,352 Views)