Pages: [1]   Go Down
Author Topic: 360 relays  (Read 2427 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 1
Posts: 43
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi everyone,

I need to control 360 5V-relays with my Arduino (only one relay will be active at one time). From my search, 74HC595 seems to be the best candidate. I will need 45 units of 74HC595 since each 74HC595 can control 8 bits or 8 relays. Does anyone have a different approach that can help me reduce the number of 74HC595 required?

I came across a posting by Azi where he stated "I am using 8 shift registers per 3 pins, for totally controlling 225 relays". I have messaged him and am waiting for his reply. In the meantime, would anyone know how it is possible?

Thanks,
George
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 331
Posts: 16470
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

First I think we would need to know what the current consumption for the 5volt relay coil is. As without that key information a 74HC595 output pin may or may not be up to the task of powering that relay's coil, and the thought of having to use 360 switching transistors is rather ugly.

Lefty

Logged

Offline Offline
Newbie
*
Karma: 1
Posts: 43
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The relay is Songle SRD-05VDC-SL-C. It is rated at 0.36W, so the current consumption is around 72ma. This seems a bit high and strange because I can control the relay just fine with my Arduino UNO.

I am powering up my Arduino using an external 12V/15A supply. I will likely need another external 5V supply just for the relays since 72ma x 45 = 3.24A, which is greater than 1A rating from Arduino 5V voltage regulator.
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 331
Posts: 16470
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The relay is Songle SRD-05VDC-SL-C. It is rated at 0.36W, so the current consumption is around 72ma. This seems a bit high and strange because I can control the relay just fine with my Arduino UNO.

Because you can does not me you should. You risk real damage to arduino pins drawing that much current. Why don't you wire a relay coil directly to +5vdc and take a current measurement with your DVM. That will give you the answer and the point you to what devices can provide that much output current.

I am powering up my Arduino using an external 12V/15A supply. I will likely need another external 5V supply just for the relays since 72ma x 45 = 3.24A, which is greater than 1A rating from Arduino 5V voltage regulator.

But earlier you wrote:  "I need to control 360 5V-relays with my Arduino (only one relay will be active at one time)." So now you are going to power how many at a time? If you are only going to power one at a time on then it would seem to be very uneconomical to size a power supply that could power all of them at one time?

Lefty
« Last Edit: February 28, 2012, 03:17:27 pm by retrolefty » Logged

0
Offline Offline
Tesla Member
***
Karma: 114
Posts: 8899
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Below are some control setups that might be of interest. If you are just powering one relay, the power requirements should be fairly small, powering one relay and its transistor, and all the chips. You just need to figure out how much current will be needed and compare that to the available power from the arduino. A safer bet would be to use an external power supply. 

http://computerchristmas.com/christmas/link-how_to/HowToId-25/Build_a_1024_Port_Controller_for_100

http://computerchristmas.com/index.phtml?link=how_to&HowToId=4

http://thehormanns.net/new/parallel320.phtml
Logged

Consider the daffodil. And while you're doing that, I'll be over here, looking through your stuff.   smiley-cool

Offline Offline
Newbie
*
Karma: 1
Posts: 43
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks guys. I just realized that there was a J3Y transistor on my relay module input trigger. The measured current consumption at the input trigger is around 6.5mA, so it's safe for the Arduino output pins. As for powering the relays, I will definitely need to use an external 5V power since the current draw will be around 3A+.

So back to my other question. Do I really need 45 8-bit shift registers in order to control 360 relays? Any way to reduce the number?

Many thanks,
George
Logged

Massachusetts, USA
Offline Offline
Tesla Member
***
Karma: 178
Posts: 8064
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

So back to my other question. Do I really need 45 8-bit shift registers in order to control 360 relays? Any way to reduce the number?

Since you only want to turn on one at a time you could put them in a 24x16 matrix.  That would get you down to 5 shift registers.
Logged

Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Offline Offline
Newbie
*
Karma: 1
Posts: 43
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, John. A matrix layout is great: 3 shift registers to control the columns and 2 shift registers to control the rows. Does that mean I need an OR gate at the row-column junction, i.e. relay input trigger? Or can I simply connect the output from the row/column shift registers to the relay input trigger?

*** Correction. I will need an AND gate, e.g. 7408, at each row column junction. With 360 outputs, I will need 90 7408 AND gates. I am wondering if I am better off with 45 shift registers instead.
« Last Edit: February 29, 2012, 03:09:34 am by daytrader152 » Logged

Massachusetts, USA
Offline Offline
Tesla Member
***
Karma: 178
Posts: 8064
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, John. A matrix layout is great: 3 shift registers to control the columns and 2 shift registers to control the rows. Does that mean I need an OR gate at the row-column junction, i.e. relay input trigger?
Let's assume 24 rows and 16 columns and that your shift registers outputs can source and sink enough current to drive one relay.  Three shift registers source current to the rows directly.  Two shift registers sink current from the columns through diodes.  If you set all rows LOW there will be no current flow.  If you set all columns HIGH there will be no current flow (because of the diodes).  If you set one row HIGH and one column LOW current will flow through the one relay that is connected between that row and column.
Logged

Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Canada
Offline Offline
Sr. Member
****
Karma: 0
Posts: 318
Sometimes teaching, always learning,
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

It still isn't clear if you need to power more than one relay at a time...
Logged


Offline Offline
Newbie
*
Karma: 1
Posts: 43
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Only one relay will be active at one time.

Thanks, Johnwasser. I have taken your advice and managed to build something that works. For those who may encounter the same issue, here is what I have done to make the relay circuit with two inputs work. Basically you take this relay circuit:

http://www.arduino.cc/playground/uploads/Main/relays.pdf

And add another resistor-transistor combination to the emitter of the first transistor, which essentially becomes an AND gate. Now the relay will be active only when both inputs are HIGH.


Logged

Pages: [1]   Go Up
Jump to: