LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

connecting hardware(connected to myDAQ) to my labview program

Hi,

I have a labview program that will send an email (Gmail) when you click the " Button " in the program but 
i need to modify it so that when i press a switch button at my hardware(connected to myDAQ)  the email will be sent ; meaning to replace the " Button " with my hardware 's switch button.

Consulted with my lecturer and she says something like inputing logic 1 into the mydaq/labview to run the process.

I have attached my program below.

Any help is greatly appreciated!

*I'm using NI LabVIEW 2013 SP1 (32-bit)



P.S : i know this is the 2nd thread i created but i'm not sure how to close that one(i have already selected a solution) 

0 Kudos
Message 1 of 4
(2,674 Views)

In order to use your signal input instead of your button, you need to read in the signal as a boolean. Digital inputs are already in the form of booleans (just like how your digital outs are set up), but if you are pulling in the trigger through your analog inputs, you'll just have to add some threshold logic to convert from an analog value to a boolean.

 

If you have digital inputs, just set it up the same way you have that DAQ Assistant in there already reading in analog inputs and wire the boolean trigger to the same case structure as your button.

 

Your teacher probably means channel 1 is your trigger input when she says "logic 1". This just means if you're pulling in multiple channels, that you use channel 1 as your trigger (which is actually the second channel becauce indices in LabVIEW are base zero).

Actually, after thinking about it, maybe your teacher is pointing out that you need to add logic to read in a value of 1 as True? This makes me think you're reading an analog input as your trigger and you need to use logic so that a value of 1 is True.

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


0 Kudos
Message 2 of 4
(2,653 Views)

Hi James thanks for the reply,

Do i have to use the Analog to Digital VI?
I'm actually pretty lost on that and can't seems to find a tutorial on the VI

 

0 Kudos
Message 3 of 4
(2,624 Views)
What analog to digital function are you talking about? That doesn't at all correct. You can easily create a DAQ Assistant for a digital line just like you created one for an analog input or use the more flexible DAQmx functions.
0 Kudos
Message 4 of 4
(2,613 Views)