02-20-2019 11:18 AM
Hello,
I have created a program that logs vacuum and temperature of a product. I want to continuously display the live data on a graph but I noticed that when the program is running, there are breaks in the vacuum waveform (blue line). It is as if data is not being logged or read periodically. I tried playing with the sample rate but nothing helped. Any advice is appreciated. Thanks!
Solved! Go to Solution.
02-20-2019 11:39 AM - edited 02-20-2019 11:44 AM
Do you see any errors?
I have had issues in the past sampling too slow. This may be causing part of the problem. I would also suggest that you offload the processing and saving of the data to the bottom loop. Have the data stream to a control them process it somewhere other than the loop you are using to do the data acquisition. You may have to over sample a bit and then average to get the card to give consistent data flow.
How do you have the channel connect to the 9201?
02-20-2019 12:00 PM
1. Since all of your modules seem to be on the same chassis, you should be able to just create 1 task for all of your channels. This will make your code quite a bit simpler.
2. Use a Producer/Consumer setup to move your logging to another loop. This will allow your DAQ loop to keep a good, steady pace while you just log the data when it comes in.
02-20-2019 06:45 PM
I used 1 task for all my channels and it fixed the problem.. Thanks,