LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

digital output for NI6009

Hi,

 

I have set up a simple program to output a digital signal (0 to 5V) using a NI6009. I tried to read the output using its analog input and it works fine. However, when I try to connect the digital output to a the input of a solid state relay, the output signal only goes up to 1 or 1.5 V. I tried to use a simple voltage follower but the output is still not close to 5V. I wonder if there's something wrong with my NI6009, or the way I have connected the signal tot he voltage follower.

 

Can someone please try to give me some advice on how to debug/fix this?

 

Your help is greatly appreciated.

 

Thanks,

 

Anson Wong

0 Kudos
Message 1 of 47
(5,945 Views)

The relay almost certainly requires more current than the 6009 can source. This has been discussed numerous times. I always used ULN200x devices when I had to drive multiple relays with digital outputs.

Message 2 of 47
(5,939 Views)

@Dennis Knutson wrote:

... I always used ULN200x devices when I had to drive multiple relays with digital outputs.


Ditto.  ULN200x works great.  As an alternative, you could use a 2567 relay driver instead of the 6009.  The relay driver can drive up to 600 mA.  Enough to turn on most relays.  I think it is available in PXI or PCI format.

- tbob

Inventor of the WORM Global
Message 3 of 47
(5,927 Views)

What are the input specifications for the solid state relay?

 

May just need a simple buffer, optoisolator or transistor to squeeze out a few more mA to drive it.

 

-AK2DM

~~~~~~~~~~~~~~~~~~~~~~~~~~
"It’s the questions that drive us.”
~~~~~~~~~~~~~~~~~~~~~~~~~~
0 Kudos
Message 4 of 47
(5,916 Views)

Hi Dennis and tbob,

 

Thank you so much for your quick reply. I purchased a ULN2001A as you suggested and connect it in between the NI6009 and the relay. However, for some reason, whenever I connect the digital output of the NI6009 to the input of the ULN2001A, the same problem happens (5 V drops to 1.3 V). I believed that I must have done something wrong when I connect them together. Please see the attached picture for the schematic of my circuit diagram. It will be great if you can advise what I have done incorrectly to cause the same problem.

 

Thanks in advance for your kind information.

 

Cheers,

 

Anson

0 Kudos
Message 5 of 47
(5,908 Views)

Is your solid state relay an optoisolator?  Sounds like it is.  If so, the input is just an LED inside a package.  Or it may be a transistor.  Whateve it is, it will have a forward voltage drop of about 1.4 volts.  That is why you are seeing this voltage drop to 1.3.  In this case you don't need the ULN2001.  You need a resistor between the 6009 output and the solid state relay input.

 

 Use V=RI to determine the resistor value needed.   Look at the spec sheet for the relay. It will tell you the typical forward current (I).  The voltage drop (V) across the resistor you need will be the output voltage of your 6009 minus the 1.3 volt drop across the relay's internal LED.  Then calculate R=V/I to get the resistor value in ohms.  Put this resistor, or anything close to it, inline between the 6009 and the relay.  Please check to see if the 6009 current drive is less than the relay's current drain.  Look at the spec sheet of the 6009 to see its max current drive.

 

- tbob

Inventor of the WORM Global
0 Kudos
Message 6 of 47
(5,898 Views)

Hi tbob,

 

Thanks for the quick response again. I will definitely give that a try tomorrow. However, it is weird how I still see the voltage drop to 1.4 V when I connect the digital output of NI6009 to the input of ULN2001A, and even when I leave the relay unplugged. Did I connected it incorrectly? (You can refer to the circuit diagram that I attached in my last reply)

 

Thanks in advance for your kind advice!

 

Cheers,

 

Anson

0 Kudos
Message 7 of 47
(5,889 Views)

Anson,

 

If you look at the datasheet for the ULN200x devices, you will find that the ULN2001 has no base resistor so it looks like two diodes to ground from the input.  Since you are driving it from 5 V connect a resistor of about 2700 ohms between the 6009 and the input of the ULN2001.  The ULN2003 has that resistor built in for ease of connecting to 5 V logic.  The ULN2004 has a larger resistor for higher voltage logic.  The ULN2002 has the larger resistor and a series zener diode.  When in doubt, read the datasheet!

 

Lynn

Message 8 of 47
(5,875 Views)

@Anson Wong wrote:

.., it is weird how I still see the voltage drop to 1.4 V when I connect the digital output of NI6009 to the input of ULN2001A, ...


It seems as if I read you rpost wrong.  I thought you were connecting to the relay itself instead of the ULN2001A.  My mistake.  However, my response still applies, and it agrees with Lynn's reply.  The 1.4 volts you are seeing is the drop across a diode (or two).  Standard rectifier diodes have a forward voltage drop of 0.7 while LEDs are 1.4.  You still need a resistor.  Lynn's suggestion of 2700 ohms is probably right.  You may want to do the math yourself for practice.  Then you would know how to do it in the future.

 

Now that I think about it, I was using the ULN2003, not the ULN2001 in one of my past projects.  I had no idea the ULN2001 did not have a series resistor built in like the 2003 does.  I still learn something new every day on this forum.

 

- tbob

Inventor of the WORM Global
0 Kudos
Message 9 of 47
(5,855 Views)

Hi Lynn,

 

Thank you for your suggestion! It is finally working now.

 

Thanks a lot!

 

Cheers,

 

Anson

0 Kudos
Message 10 of 47
(5,820 Views)