USB Power Supply Switch via Relay

Thread Starter

DustyBottoms

Joined Jun 30, 2019
2
Hello,

my question is a simple one, please don't laugh. :)

I want to power on and off a USB device via a relay. I already programmed it. My question is pretty basic:
I need to connect the red cable (+5V) to the relay to on and off the device, but do I also need to connect the black cable (ground) to the relay, or can I just connect the ground cables directly?

Thanks!
 

MaxHeadRoom

Joined Jul 18, 2013
28,684
Are you using a signal from the USB to switch the coil, or using the 5v+?
If so, how do you intend to switch the coil, or are you referring to the relay contacts?
A little more explicit would help.
Max.
 

djsfantasi

Joined Apr 11, 2010
9,163
Welcome to AAC! Since you’re a new member, I’d like to point out a couple of things.

Here at AAC, it’s preferred to upload all content to be hosted here. That way, broken links or external sites that may contain viruses or have security won’t affect the usefulness of your content.

Below the text box when you write a post, is s button to upload content into AAC. please use it to upload images, etc..

When posting code, there is an icon above the text box, that kinda looks like a monitor. That is the correct way to post code.

I hope you find this helpful.
 
Top