Relay Power Supply Failure ?? :C

I have a 12v relay card (2-port) having a maximum driving ampere of 8A ...

my sketch design is to just turn on/off something (within the capabilities of these relay card) .. i supplied my arduino uno with a 12v 1A adapter... i supplied the relay card power from the Vin and Ground coming from the Arduino .... Everything did good when i did the switching process . the led indicator of the relays are lighted bright and stable, meaning the relay switched something with an "ON" state HOWEVER ... i provided the relay card with their own power supply from 12v 1A adapter before the switching process, the led indicators of the relay card are already lighted but not much light (and it seems to be flickering),,, when i did the switching, the relays toggled but they failed to maintain their states and seem to turn off... Why is that ? the specs of the adapter of the arduino and the adapters i used in the relay cards are just the same.......

(deleted)

Sounds like you didn't connect power supply GND and Arduino GND together.

these are the setups

i just want to aim for separate power supplies for the arduino and the relay card

(deleted)

ok sirs , but what if i use a 12v 1A adapter and a 12v 14A supply for the relay card and connect their common grounds?
is that ok ???

Yes that is not only OK, but also necessary. The relay and Arduino need to have a common ground. Attached is a schematic.

Capture.PNG

thank u sir, also, i'm not sure what is the maximum amperage that can be supplied for the arduino uno, reasearch results in the web have been confusing, may i ask sir what is the max current that can be supplied to the arduino ???

So the Arduino uses a certain amount of current at a certain voltage (or in other words a certain amount of power in watts). It doesn't particularly matter how much current you have available as long as it is above the required minimum current - at or above the minimum rated voltage.

Technically there is more to it because the on board voltage regulator will be dissipating any excess power you give the board, but as long as you pick a power supply of 7V, 9V, or 12V and 1 amp max current output you will be fine. All that means is that the power supply is able to deliver up to 1 amp of current at the rated voltage and if you start drawing more current the voltage will start to drop off and become lower and unstable. But the Arduino draws nowhere near 1 amp. I don't know the exact current draw (and it varies slightly depending on how many pins you're using, what functions you're using, etc.) but it will certainly be far less than 1 amp.

There are also limits to how much current you can draw on each pin of the Arduino however, but that is a different topic and is documented on Arduino's appropriate webpage for each device. For Arduino Uno it is 40mA per pin. All that is specified here: http://arduino.cc/en/Main/arduinoBoardUno

To be honest I would recommend using only a single power supply. The only reason you would need a dedicated power supply for the relay would be if you were going to be pushing something > 12V though the relay in which case putting that much voltage into the Arduino voltage regulator can heat things up and cause issues. The other reason you might need one is if you were switching on a large motor or something that would cause a spike in voltage or drop in voltage on the power supply that could adversely affect or even damage your Arduino.

But if you are only powering something like a small motor you could probably easily get away with using a single 12V 14A power supply and just connecting the positive rail to the relay and to the Arduino.

What will you be controlling with your relay?

thank you sir ,,, but sir i'm planning on more complex projects, like driving several shields and output components with input supplies greater than 12v ...that's why i want to use an external supply for each shield and component, and i don't want to encounter trouble when it comes to these power supplies ,, so i'm thinking of using the power supply from the link below sir ....

http://www.instructables.com/id/Power-Supply-For-Arduino-power-and-breadboard/

what do you think ? i just don't want the shields' power supplies to come solely from the arduino sir ..

and by the way sir, for my current project , i'm going to drive 4 pcs of 28V 7W LED Lights by using 2 relay cards (2port)

At 28V and 7W each LED light will be pulling 250mA. So four of them will draw 1 amp or close to it.

You specified the relay card has 2 ports and can handle up to 8 amps. It's unclear if that is 8 amps per relay or 8 together (4 per relay); but either way you will be able to safely use just one of the relays to power 4 LEDs. Assuming you power the relay with a power supply that produces 28V and at least 1 amp of current. I would say get one that produces like 8 amps of current if you are intending to use this for future bigger projects that require driving things with lots of power such as many of these LEDs.

It is definitely understandable given the higher voltage to use a separate power supply. You do have one other option though and that is to get a voltage regulator of your own (switching kind for instance) that can step down the 28V to the 5V the Arduino wants and then feed that 5V line directly into Vin; bypassing the barrel jack and on board regulator on the Arduino.

http://www.dimensionengineering.com/products/de-sw050 (Note I have never used this exact regulator or bought anything from this exact website, link is just for reference I am not endorsing them)

As far as if you want two seperate supplies I would go with this for Arduino - https://www.sparkfun.com/products/298

and something much beefier for relays. - http://www.acopian.com/power-supply-voltages/28-volt-power-supplies.htm (Just make sure you get one with enough current output)

You are correct in not wanting the relay power to come from the Arduino. That would burn out your Arduino faster then you could unplug your circuit. Because the 5V line on the Arduino is: a) only 5V not 28V b) also has a current output limit well under 1 amp

So either use two different power supplies or use one supply big enough to power relays and then step down voltage with regulator for Arduino.

spycatcher2k:
Have you connected the grounds together?

OK now, you are describing a “12v relay card (2-port) having a maximum driving ampere of 8A”. Are we perhaps referring to this one, or something essentially like it, with opto-isolators?

If so, there is a catch - you do not connect the grounds together!

More specifically, you remove the link shown between “RY-VCC” and “VCC”; you connect “RY-VCC” to your 12V relay supply and “GND” to your 12V relay supply ground, but no “GND” terminal on the relay card to your Arduino ground.

You connect “IN1”, “IN2” and “VCC” to the corresponding pins on the Arduino (Note: “Vcc”, not “Vin”). You drive the Arduino pins LOW to switch on the corresponding relays.

Connecting “VCC” on the relay card to 12V will cause the erroneous behaviour you (more-or-less) describe.




Edit: Here’s the clue:

Previous discussion.

Hi Sirs sorry for the late reply ,

Sir Wes,

is it necessary that i always connect all the shields (i'm about to use in the future) with common ground to the arduino? may i have a good explanation sir why just for my knowledge sir tnx... and also sir, can you give me an example of schematic of connecting more than 2 shields with separate power supplies (probably more than 12v and 1A) , but with common connection to the ground of ARduino ? it will be well appreciated sir tnx a lot !

Hi Sir Paul, this is the relay card i used…

relay card.pdf (98.6 KB)

As Paul pointed out if using a shield with an opto-isolator then:

If so, there is a catch - you do not connect the grounds together!

This in general proves that not every board and shield should have common ground with the Arduino. Although in general most do require a common ground. It depends entirely on the circuit that is on the shield and what you are trying to do.

So I can give you no concrete answer other than usually a common ground is required (and the reason for that is pretty much basic electronics, go watch some YouTube videos about it and you will start to understand why ground is necessary, but basically it provides a reference for all other voltages. It does more than that too but that's a good basic explanation I think.)

But the real answer is for any shield you buy and use you need to read and analyze the datasheet/schematic and understand what is happening and how to use it.

As far as connecting two shields... it depends. If they are shields that stack into the existing headers on the Arduino all the leg work is done for you, it's just plug and play. If it's relay shield you are talking about, then basically once you understand how one works you can take that same method and apply it to additional relay boards. Not infinite of course since there are limitations to the Arduino hardware.

And from the pdf you posted it appears the relay card you are using has no opto-isolators, so in this case you do need a common ground between Arduino and relay shield.

I am assuming you know how to connect NO, NC, and COM. So I will not cover those pins. If you don't know how NC, NO, and COM work, I would suggest watching again some YouTube vids to demonstrate that, because you will learn just as much from that and probably better explained then I could explain here.

V+ is the voltage to activate your relay coil, so that depends entirely on the relay, but usually 5V is the magic number for most relay shields. But make sure to get that 5V from the power rail not an I/O pin since usually the relay coil take more current than a single pin can provide.

You only need to connect one ground pin to Arduino ground, as all grounds on the relay shield should be electrically connected.

To be honest I'm not sure what dry contact input is (I'm sure someone with more knowledge than me can answer that), but from the schematic it appears to be a direct connection to the relay coil which may or may not be useful in certain cases. But in this case you are using a logic level device (Arduino) so you should connect I/O pin to logic input and set output pin HIGH to enable Relay.

wes000000: To be honest I'm not sure what dry contact input is (I'm sure someone with more knowledge than me can answer that), but from the schematic it appears to be a direct connection to the relay coil which may or may not be useful in certain cases. But in this case you are using a logic level device (Arduino) so you should connect I/O pin to logic input and set output pin HIGH to enable Relay.

It means that if you are using a logic input such as an Arduino, you connect the logic input and ground. You could alternatively connect an ordinary pushbutton, switch or whatever between "dry contact input" and the same ground point to actuate the relay. If you were to connect a port pin of the Arduino to this, some seriously odd stuff would happen - possibly what was originally described. :astonished:

is this right sirs ?