Please post a link to the datasheet for your relays. A lot depends on the type of relay you are using. If the Arduino only needs to provide ON/OFF signals with very little current then there will be no problem.
Robin2:
Please post a link to the datasheet for your relays. A lot depends on the type of relay you are using. If the Arduino only needs to provide ON/OFF signals with very little current then there will be no problem.
You should never just try stuff to see if it works - adding components without checking data sheets or googling to find out how , is bad practice , you could easily destroy something
aarg:
Did you configure the jumpers as on page 3? Can the Mega supply the 750mA specified at the top of the same page?
Yup i configured the jumpers sure for 5v.
That's what i'm asking, if i got a power supply 5v 700 - 800 or 1000 mA, maybe 2 amps as i got 3 relay boards that will be the solution to be able to open all relays at once with no problem? right.
Sorry for asking basic questions but i'm new to the field of hardware
hammy:
You should never just try stuff to see if it works - adding components without checking data sheets or googling to find out how , is bad practice , you could easily destroy something
yes, you are right of course, i didn't try the 20 relays at once yet i'm asking to know what should i do
"can an arduino mega handle 20 Relays on at the same time?"
You should be able to use your multimeter to measure the amount current being supplied by the mega pin to operate the relay, and then see if that current level is within the pin specifications of the mega.
KareemWaheed:
Also on the same topic, if i used a NPN Transistor with 1k resistor from the output pin to the relay signal will it help in anyway?
I had a second look at the module. Unfortunately there is no schematic. I would never work with a board like this with no schematic, unless I could make one my self from probing the board.
It does seem like the relay coils are driven directly from the digital outputs. We can not see the back of the board. Does it have clamping diodes on it, and/or transistor drivers? If not, driving it directly from the Arduino outputs will be a disaster due to back EMF spikes from the relay coil. This is a separate issue from the total current limitation.
Unfortunately, there are a lot of vendors/manufacturers that don't diligently document and represent their products. In the old days, techs and engineers would spot the gaping holes in a spec sheet like this, laugh the product off the block and find a better one. Also, because of this, it is increasingly difficult to train people to read a proper sheet, and what to look for.
KareemWaheed:
Also on the same topic, if i used a NPN Transistor with 1k resistor from the output pin to the relay signal will it help in anyway?
A logic level relay board probably should already have one. The voltage select on the input input control pin may be just changing a resistor value that feeds a transistor.
These common blue sugar-cube relays draw about 75mA coil current, so your 5volt supply must be able so provide at least 1.5Amp when all 20 are 'on'.
I think you should have bought a version of the relay board with opto couplers.
No opto couplers and a shared ground with coil circuit and Arduino could mean reset trouble when switching inductive loads.
Leo..