… then put it between the IO pin and the relay. That is the only place a current limiting resistor makes sense. Or, you could use the transistor trick and add a transistor to power it.
Can I ask how you measured the current? I would have expected (but have not checked) that VIN or VCC pin would have been where the larger current source was drawn from, not the signal pin. Especially since the eBay item lists:
I also thought that a current limiting resistor would make sense to achieve the 15-20mA you mention, but I have tried a big one 47K which does not work, and a small 470 which limits a little bit. How can I calculate the optimal value?
if all you’re measuring is the overall system draw with a USB sensor, a current limiting resistor won’t change that. The relay needs power to remain energized. Measure the current draw through your IO pin only, that will tell us how much it draws thru the pin (which is the only value of real consequence in most cases, as you don’t want to burn up an IO pin!). You can do that with a multimeter in current mode in line with the IO (so it goes IO pin, resistor, multimeter red lead, multimeter, black lead, relay IN pin). A EEVBlog uCurrent would be more accurate, but a multimeter will give you an indication.
@ njbuch - High quality and low power consumption relays costs a lot (look at mouser and alike). So I am not surprised that that particular relay + LED consumes 150mA, however it is a bit on a high side. GHI’s relay module consumes about 75mA.
By reducing current to your relay with a series resistor you will get two problems: instability and inability to turn on completely.
agreed. Using a USB measurement device is surely only showing total system load
Are we not meant to do overkill on everything we can? But I agree, for 150mA you’re not overly worried about total accuracy, but once you get in the 15mA ballpark to measure just the IO pin draw you’re starting to get into an area where the multimeter burden voltage can be impactful on readings
[quote=“njbuch”]I have another case where I need a VERY little power consumption on the relay, what should I look for at mouser.com??
You should look for Coil Current or Coil Resistance (the higher - the better).
Depending on the application, you should consider SSR, mosfet, transistor etc.
There is an opto isolator on that board which is used to control the relay. The opto isolator then drives a transistor which controls the relay’s coil. Typically an opto isolator needs ~ 10-15ma drive current. What is not shown on that ebay page is if they already have a series resistor built into that board or not. And if so, what is the control voltage input for 5v or 3.3v?
if no resistor on the board, then you need to add one, otherwise you could blow the opto.
[quote=“VersaModule”]What is not shown on that ebay page is if they already have a series resistor built into that board or not.
Seller would be getting lots of returns if it there was no series resistor for optocoupler
Kind of defeats the purpose of having an opto when you have to supply the board and use the common ground. It would function just as well with a transistor driver alone and draw far less to switch the relay from a GPIO input.
What you are seeing is the total power to switch the relay. 5V relays draw higher current that say a 12V one but for the same size relay, the power would be very similar.
The datasheet for the relay shows that it draws a nominal 71mA but you have 20mA for the opto and I can see another LED for switching indication with again, probably around 20mA draw.
If you want to lower the overall current on this board, remove the LED or at least the resistor for this.
Find a relay that will be lower power draw will be hard without knowing what voltage you are switching. Is it AC or DC for instance. For AC is easy, use an SSR. For DC you could just use a high sided FET driver. Only current draw then is the gate current and that will be quite small. Tell us what you are switching and maybe then we can advise more.
@ njbuch - Hi, I think the high current is the current on the collector side of the opto-coupler. I think that you have connected this “Vcc” to the 5 Volt line of the Spider Mainboard. I think it is not needed and not advisable to use this as the power supply to feed the primary loop of the relay since you might get voltage peaks on the power supply of the mainboard. It would be better to take a separate 5 Volt power supply on the collector side of the opto-coupler, which can even be generated from the high voltage side of the relay.