0
\$\begingroup\$

I have an LED strip being controlled by an Arduino and powered by a molex connector within my PC. I'd like to have my Arduino connected to my computer via USB 24/7, however when I do this, the molex grounds itself through the USB connection when I toggle the switch to the off position, so the LED strip does not turn off when I want it to. Also, I don't feel comfortable grounding molex through USB. Is there any way around this? I have a reasonable background with electronics, but I'm just not sure what to do in this case, and I couldn't find anything on the internet. Thanks.

schematic

simulate this circuit – Schematic created using CircuitLab

\$\endgroup\$
7
  • 1
    \$\begingroup\$ It sounds like there is another ground loop that you aren't aware of seeing as how the light doesn't turn off. Keep in mind that, ideally, the USB that your arduino will be connected to will have a common ground with that Molex connector so you won't be grounding it through the USB its just you'll be connected to the same ground. \$\endgroup\$
    – Funkyguy
    Dec 22 '14 at 3:46
  • \$\begingroup\$ Well yes, they have a common ground in the computer's power supply. I looked up information on ground loops prior to posting this question, but I didn't really get anything substantial from any pages I visited. Could you provide some reading for me and/or explain it? Is there any way to get around this and use USB to power the Arduino and use molex to power the lights? \$\endgroup\$
    – ArmaAK
    Dec 22 '14 at 3:52
  • 1
    \$\begingroup\$ Ground loops wasn't exactly the right term to use, sorry. I meant basically another complete circuit. I can't provide any reading but the idea is pretty simple. Getting around this would mean you'd have to sever the USB connectors on your PC from the rest of the computer. It'd be better to have a discrete AC to USB thing, like a phone charger, just make sure its high quality. Your GND will be separate than the other GND and the only interaction your Arduino will have is to the transistors on the sinks of the strip. \$\endgroup\$
    – Funkyguy
    Dec 22 '14 at 4:04
  • \$\begingroup\$ That's what I'm doing currently for this project. I'm routing in a 9v AC adapter to power the Arduino so it is totally separate from the computer's power supply. I'd really like to have it powered by USB though, so I could change the code whenever I wanted to and also so it would turn off when the computer turns off. \$\endgroup\$
    – ArmaAK
    Dec 22 '14 at 4:06
  • 1
    \$\begingroup\$ Well if you want to be able to do that, then you're going to be connected to a similar ground as the Molex. Can't really get around that unless you want to modify your own PC \$\endgroup\$
    – Funkyguy
    Dec 22 '14 at 4:07
1
\$\begingroup\$

I can see why you'd wand this since it'd be really nice to be able to reprogram the arduino at every time although having separate grounds while still connected to the same PC is going to get a little hairy.

The USB and the Molex connector share a ground internal to the computer so if you wanted to separate that, you'd have to modify the USB board to use a different ground. This gets into heavy PC modding and can get pretty hairy quickly.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.