Hi Everyone,
New to this board, I'm having a couple of problems in our labview development.
A bit of context : we're trying to do some data acquisitions and display on some analog inputs (Pressure NI9205 / Temperature NI9213) and some frequencies (through a NI9401).
P and T° are sampled at 100Hz though I plan to turn it down to 20Hz.
Frequencies can go from 100Hz to 9000Hz for one counter and from 0,5Hz to 80Hz for the other. They are sampled... well, when they can!
I'm using Labview 2017 under Win 10.
- 1st problem :
While the T° and P seem to work well, the frequencies are giving me a hard time and have quite a weird behaviour.
Even under the test panel of NI Max, the results I get are a bit off from the real signal and also seem to glitch every now and then.
For example : I have 3242Hz on PFI1 and I'm trying to measure that frequency. The acquired / display data will show 3400Hz and will sometimes glitch to 4000Hz or even a super high frequency.
I've tried putting a digital filter on it with a 6,425e-6s minimum front but that didn't change anything.
Moreover, the real signal is pretty clean and when measured with a simple frequency meter is rock solid and precise to the 1/10Hz.
I would tend to think that this is a soft problem but then again, the NI-MAX test panel shows the same kind of behaviour...
- 2nd problem
On another front : there is also a sync / acquisition speed problem with these frequencies.
I.E : in order to have these frequencies "sync'ed" with the T° and P that I sample at 100Hz, I would like to also write them at 100Hz even though I have no new measurement available.
In order to do so, I put a shift register on the while loop and a condition structure that just writes the previous measurement if no new one is available (and also cancels the error and writes a 0 in case of no signal at the input / timeout).
Problem is that I still only record about 100 times less frequencies points than T° and P.
The 100 number is not precise though so no conclusion to jump to on this.
For example : In a TDMS, I have 115000 T° and P points but only 1750 points of frequency 1 and 1375 points of frequency 2.
Well, I think I've covered most of it.
An extract of the VI is enclosed.
Hope that rings a bell to someone!
Thanks for your help,
Marc