11-25-2013 08:59 AM
Hi,
I have this VI to calculate the frequency and I need to use the frequency to calculate my scan rate...But the value of the frequency is required to calculate the scan rate....How do I take the value of the frequency here?Example I need 10000 Hz as the value of the frequency for my further mathematical calculations.Please help
11-25-2013 12:49 PM
Maybe I'm not understanding your question but I don't see where your problem is. You HAVE the frequency data in an indicator called "Frequency (Hz)". If you need to use it in your code then connect the indicator to the connector pane, drop the subVI into your main VI and wire the subVI's "Frequency (Hz)" output terminal to the rest of your code.*
* If you have no idea what I'm talking about, then look at some basic LabVIEW tutorials and learn how to make subVIs. You can't get far in LabVIEW without understanding that.
11-25-2013 02:10 PM
11-26-2013 08:24 AM - edited 11-26-2013 08:26 AM
I suspect that's because you left the while loop in the example code. When you make subVIs you "usually" don't want a while loop in them (unless you have set up some way to stop its loop). The reason is that it will just continue to loop and never return any data to the outer code.
You can just remove the while loop in the example code and put a loop in your main VI around your subVI. Then you will see the subVI run and update the frequency value.