10-24-2013 03:58 AM - edited 10-24-2013 04:04 AM
Hi,
I want to create a Campbell diagram for a rotating machine, in live (while the machine is rotating).
This diagram is basically a graph of the spectral content a a signal (Hz), versus the rotation speed (RPM).
I've found an express VI that seems to do what i want to do (Spectral Map, in the Sound and Vibration toolkit). The output of this VI is buffered so that it can run in live (The buffer vi is also a vi that comes from the Sound and Vibration toolkit).
The block diagram of my complete process is attached to this message, sorry it's a bit messy.
On the first run, this VI works as expected: as the machine is running up, the graph is filling up. Now if I want to make a second run-up, i need to first reset the VI. However once the vi has been reset, it won't ouput anydata!
I've tried different combination:
- Reset "Waterfall and Campbell.vi" and the buffer
- Reset only the buffer
- Reset only the "Waterfall and Campbell.vi"
None of them work, the colormap stays black.
So does anyone know how to use this express vi? I could find an exemple that works with live data and buffering.
Thanks,
Regards,
peper
10-25-2013 07:49 AM
Hello peper,
Can you share the VIs you're using?
This way I can reproduce it locally and pin-point the source.
Thanks in advance!
03-06-2014 07:47 AM
Hi,
Attached to this post, you'll find a piece of code that replicates the problem I have in my main application.
If you run the vi with an initial small frequency (the frequency dial up simulates the rotation speed) and then increase that speed, you'll notice that the spectral map gets filled as expected.
The problem arises when I try to reset the spectral map (=do a new run-up):
- I set the frequency to a minimum
- I hit the reset button (the spectral map is emptied as expected)
- I slowly increase the frequency ===> the spectral map does NOT get filled up anymore. Or it gets filled up like 30 seconds after the run up or gets partially filled up.... in summary there is something wrong with the map each time I try to reset the septral map vi.
Let me know if you need more information.
Best regards,
peper2001
03-10-2014 03:14 PM
Hello peper,
I don't know id this question is still active, so I'll keep my reply relatively short.
The last week I have been on holiday and now I have returned.
There seem to be several things wrong concerning to how your different express VIs are linked together and configured.
It's not the changing of the frequency that causes the issue.
Even if you fix your frequency to a higher value, then you see the "slow" behavior.
I would suggest (especially for a "live" VI) that you use more low-level VIs like in the ''Waterfall and Cascade Plot (Analog Tach, DAQmx)" Example VI.
03-11-2014 03:48 AM
Hi Thierry,
Thanks for your follow up.
I contacted NI support about this problem and they pointed the issue: it lies in the fact that the 'tachometer express vi' should also be reset when the spetral map vi is reset.
Futher analysis revealed that for some reason, the spectral map express vi, when reset, expects the speed waveform (the one that comes out of the tachometer express vi) to have a "t0" equal to 0! Otherwise it won't generate a new spectral map.
Concerning the slowness issue: as you suggested I removed the express vi and used the "basic" vi which seemed to speed things up a very little bit. But i think the main performance bottleneck lies in the vi which is supposed to buffer the spectral maps. Indeed, it seems that it's not preallocating memory (it uses "append to array" instead of "replace array subset") and hence can become very slow as the size of the buffer increases.
I'll try to modify it and see if things are speeded up.
Regards,
peper2001
03-11-2014 07:58 AM
Thanks for the feedback!
If there's anything I can assist you with, then just let me know.