01-02-2019 07:56 PM
Dear forum,
I am using NI USB 6229 BNC which connected to current pre-amplifier SR570 (RS232).
I use LabView 2018 (64-bit)
I found a problems that there is spike during acquisition. at first, i thought it was caused by the amplifier.
I confirmed with oscilloscope and found nothing.
So I guess it is caused by the acquisition process.
two condition that might cause the spike.
1. changing value of numeric control inside while loop.
2. during measurement (no changing at all)
Here I attached the graph.
I want to know what the cause of this spike and possible to avoid this spike during acquisition.
01-02-2019 08:00 PM
Your graph is missing.
Attach your VI as well.
01-02-2019 08:08 PM
Dear RavensFan,
Here I attached the image.
it is normal VI. acquiring some Analog Input Channel and generating some Analog Output Channel.
Everything is located inside while loop.
01-02-2019 08:26 PM
That's not a VI, but just a screen shot of part of a block diagram. What's happening in the rest of the VI that is cutoff? Is there a loop in this VI?
Those spikes seem pretty insignificant in terms of current, just fractions of 10's of microamps. Are you stopping and restarting this VI? Because I see breaks in your plots and the spikes seems to occur immediately after these breaks.
01-02-2019 08:38 PM
There is no other loop, beside For Loop for creating waveform as you might have seen.
the rest is indexing multiple waveform management.
even it is 10's uA, i think it still affects the data. the current is the result of calculation from voltage (that have been gained by amplifier SR570) and certain sensitivity. it is calculated as follows.
current = volt (V) x sensitivity (A/V).
so it there is spike on current, probably the voltage will be high too forcing the sensitivity value to be changed, so it is not overload.
the breaks on the signal were caused by the while loop. since I put everything, like DAQmx Start and Stop inside while loop, so there is a delay between acquisition each loop.
01-02-2019 09:02 PM
You say there is no other loop, but at the ned you say you put everything inside the while loop. Which is it?
Please don't tell me you are using the run continuously button.
Don't keep starting and stopping the task. Just start it once, continuously acquire in the loop, then stop the task when you stop the while loop.
01-02-2019 09:09 PM - edited 01-02-2019 09:10 PM
yes, I used only one while loop for all tasks and for loop for generating waveform.
I mean, indexing and separating multiple waveform, so I can calculate the resistance/conductance and show some graph as you have seen.
No, I were not using Run Continuously button. but, In DAQmx Timing, I use the continuous sampling mode, while to run the program I just hit Run Button.
ok i will try your advice.
forget to ask, so probably the spike was caused by stop and start the task repeatedly by while loop?
01-02-2019 09:33 PM
@abuzahra wrote:
forget to ask, so probably the spike was caused by stop and start the task repeatedly by while loop?
I don't know for sure, but that's my suspicion.
01-03-2019 07:53 PM
Thank you for your answer.
yes, probably the cause of that spike due to start and stop of looping condition repeatedly.