I'm wiring up a control box for my Ox. I have indicator led's wired up so that when my 24v psu is powered the led is lit. I'd like to also put an indicator light in for when the arduino is connected, i have an led indicator. The LED's are 24v, so I'd like the arduino to trigger a normally opened relay to send the 24v power to the led. Attached is how I have it wired, with the signal coming from the arduino 5v, but it's not activating the relay coil to closed. The arduino is powered through usb. Any help or suggestions? Thanks.
I don't understand the arduino connection to the 5V relay. How are you controlling the relay from the arduino. The 5V relay (make sure it is a 5V coil, btw). should be wired to the + and - outputs of the 5V supply and you should hear the relay click (if it's a mechanical one) when you turn on the 5V supply. You should also have a diode across the relay coils (again, if mechanical) to prevent BackEMF from damaging your electronics. Not to try to change what you are doing but you know it would be simpler to just have an LED set up for 5V and wire it to the arduino +5V output. No need for a relay. What LED are you using?
Hey Phil, thanks for the response and sorry for the delay. Shown below is the control box that I built. Housed is 4 TB6600 drivers, a 24v power supply, a few fans and an Arduino Uno w/ screw terminal for connecting to the drivers. I also put an outlet that I plug my router into - that is the switch for the router on the front of the box. Ultimately, I'd like to set up a Raspberry Pi w/ an LCD to be run the control software - I don't want to drag my laptop out and get dusty every time I'm carving. That's where I want LED indicator for the arduino. If I'm not powering the arduino through my computers USB, I would have to power it somehow, correct? That's where the 5v psu comes in I think. I may be completely over thinking this. You can see the LEDs that I have on the box. The top 4 are each connected to the driver showing that i have power to each driver. Below are two green lights - one shows that my fans are powered and the other green shows that my 24 v psu is powered. That one is redundant because if the either the fans are powered or the drivers are powered, my 24v psu is powered. Back to the LED for the arduino, I'm using 24v LED's. I can hook one up to the arduino but then the 5v from the Arduino doesn't light up as bright as the 24v LEDs and my OCD kicks in. So, my thinking is that I can use the 5v signal from the Arduino to the relay to activate the coil which sends 24v to the LED. All LED's are the same brightness and I'm happy. Again, this is for future when I will be actually have to have an additional 5v psu for the arduino since my laptop won't be powering the arduino. To supply the 5v from the arduino to the relay, I think i can use a different output - M7 and through config set up grbl to automatically output that signal on powerup. I hope this all makes sense. Basically OCD. All the other LEDs are getting 24v and if i send 5v to one, it is much dimmer.
Ah, I see. You want to match the other LEDs which all have built in resistors. Can you get a 5V version? That might be cheaper than a relay though, if you already have the relay, it makes more sense to just use it. If you can take the LED assembly apart, you could probably change the resistor to make it work well at 5V. As to the RasPI, yes, you can power it from any USB wall wart with a standard USB Micro cable. You're going to have to figure out how to get 5V from the PI to power the relay for the LED. There are several 5V pins on the 40 pin gpio connector but I would check to make sure they can source enough current to drive the relay coil. Be sure to use that diode across the relay coil. A "5V LED" would use a lot less current. The arduino would get it's power from the PI. I've run GRBL on an Arduino connected to and powered from a PI 3B. I'm hoping to get time to hook it up in the next week or so now that I've got my Nano GRBL Shield done. 24 V is available from that. I'll post more about that soon.