Counter/Timer

cancel
Showing results for 
Search instead for 
Did you mean: 

connect PCI-6602 to relay

Hello,
 
I am absolutely new to Labview and the PCI-6602 card. What I would like to do is to use Labview to control a relay through the PCI-6602 DAQ card. I am of course using the CB-68LP connector block to make the hardware connection.
Since I want to control a relay with a 0-5V TTL signal to open and close, I guess I am supposed to send a digital signal to the DIO lines on the PCI-6602. However, could someone explain to me if there is an example VI that can do this?
 
Moreover, what are the pin numbers on the CB-68LP connector block where the actual digital signal will come from? This is not clear from the manual.  I would first like to measure it on a voltmeter before connecting an actual relay to it.
 
Eventually, there will be three relays connected and each of them will in turn be controlling a solenoid valve. In some cases, two of the relays should open at the same time while the third one is closed. At other times, only one relay will open.
 
I appreciate your feedback in advance.
 
thank you.
0 Kudos
Message 1 of 7
(5,724 Views)

Hi,

Please check the Hardware Input and output>>Daqmx>>Digital Generation examples in the Example Finder (Help>>Find Examples in Labview). Write Dig Chan.vi outs one single pulse. If you choos to use Port0/Line0 on your 6602 the signal will come out on pin 10 as listed if you rightclick your device in MAX>>Device Pinouts. The connector block doesn't change the pin number.

Hope it helps.

Pelle S
Account Manager
National Instruments Sweden
0 Kudos
Message 2 of 7
(5,704 Views)

I really appreciate your answer Pelle.

However, the data array in "Write Dig Chan.vi" is configured to have 8 elements and therefore, 8 lines must be selected for the digital output as Dev1/port0/line0:7. Does this mean that the signal will come from 8 different pins?

Moreover, I could not configure the data array so that the signal will be output only from one line such as port0/line0. Is it possible.

And lastly, is this the vi that I can use to control relays since there is going to be an internal triggering mechanism from Labview that will trigger the digital output signal to the relays everytime, either to open or close.

Also, how much is the duration of this digital output signal? I may be asking too many questions but your last feedback was really helpful so now I became a bit more inquisitive.

thanks a bunch,

Fawad.

0 Kudos
Message 3 of 7
(5,687 Views)

Hi,

I have attached a modified version of the example which only outputs on one line. Notice the change at DAQmx Read.vi. The output will remain high if you stop the program.

Please clarify if you have further questions.

Pelle S
Account Manager
National Instruments Sweden
0 Kudos
Message 4 of 7
(5,668 Views)

Hello Pelle,

I am sorry I was not able to respond to your mail earlier.

Regarding the vi that you sent, it does not work for version 8.0 of LabVIEW. Is it possible for you to make it compatible for version 8.0.

Moreover, since we have the licensed version of Labview 8.0, is it possible to upgrade to version 8.5 free of charge

0 Kudos
Message 5 of 7
(5,588 Views)
Hi,
Please call your local office to clarify if you're entitled an upgrade free of charge.
Pelle S
Account Manager
National Instruments Sweden
0 Kudos
Message 6 of 7
(5,570 Views)

Hi Pelle,

I really appreciate your help sir.

I was able to generate a digital signal (0-5V TTL ) using the VI that you sent. However, since I need to simulate the loads for a Domestic Hot Water system, the digital signal should be activated through internal LabVIEW logic (control sequence) instead of the Control button on the front panel. To do this, can this same VI be modified or do I need to create another VI that could simulate the control sequence (pulse train)?

Sincerely,

Fawad.

0 Kudos
Message 7 of 7
(5,549 Views)