LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Get signal value at a specific frequency

Hello all,

 

I am creating my very first VI and I am facing an issue. I would like to generate a square wave signal and periodically compare the value of the signal with a threshold in order to produce a numeric value taking value 1 if the signal value is greater than the threshold or 0 otherwise. I have been able to find how to compare the signal value with the threshold but I am not able to find how to set the frequency of the comparison. 

 

Thank you in advance for your help !

Kind regards Smiley Happy

 

Alex

0 Kudos
Message 1 of 5
(2,717 Views)

I would suggest that you take some time to go through some of the many free tutorials on LabVIEW that are on the Web (a couple of the popular ones are listed in my signature). For example, they will teach you about loops, which is what you need to use here. It will be much more efficient (and quicker) to learn the fundamentals systematically than to ask questions here about each step of the way (there is always a time lag between Q and A).

 

Cameron

 

To err is human, but to really foul it up requires a computer.
The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
Profanity is the one language all programmers know best.
An expert is someone who has made all the possible mistakes.

To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):

LabVIEW Unit 1 - Getting Started</ a>
Learn to Use LabVIEW with MyDAQ</ a>
0 Kudos
Message 2 of 5
(2,702 Views)

I am not able to open your LabVIEW 2012 VI, since I still have 2011 SP1 running here.

However - a simple "Wait until next Millisecond mutiple" or a "Wait" from the timing palette would probably be sufficient here. See attached sample code.

0 Kudos
Message 3 of 5
(2,700 Views)

Thank you to both of you ! I will take a look at the sample code and docs you provided to me.

0 Kudos
Message 4 of 5
(2,691 Views)

Hi alexaviator,

Please see the help menu before using the VIs. also connect it properly in the frequency part.

Use atleast CTRL+H for references .

 

Boldness has genius, power and magic in it!'
0 Kudos
Message 5 of 5
(2,687 Views)