On/Off Switch USB Cables & Power Adapters for Development Boards

Many development boards don’t have a power switch, and simply boot when you apply power. So if you need to turn off and turn on your board, you’d either remove the power cable and re-insert it, or do the same with the power adapter on the power strip or socket, but the latter is not always convenient, and the former may damage the power connector, especially if the board uses a fragile micro USB connector for power. The solution to this small problem is to use a USB cable with an on/off switch.


The example above is a 5V/2A with a switch button with the plug working with Orange Pi, Banana Pi M2, and other board using a 4mm jack (like PS4) for power. That model sells for $3.90 on Aliexpress. Another solution is instead to buy a short USB cable with an on/off switch instead for just around $1 on eBay, plus a male USB adapter or cable to whatever power input connector your board uses.

USB_on-off_switchIf instead you’d rather have some fun and make your own USB on/off switch cable, there are instructions for that.

Thanks to Onebir for the idea.

Share this:

Support CNX Software! Donate via cryptocurrencies or become a Patron on Patreon

ROCK Pi 4C Plus
Notify of
The comment form collects your name, email and content to allow us keep track of the comments placed on the website. Please read and accept our website Terms and Privacy Policy to post a comment.
6 years ago

I can’t recommand to buy this interruptor (not the cable usb) on picture, i bought ten on aliexpress, perfect for led (100-500ma) but the switch is crappy with high resistance so for high load (500-2000ma) don’t be surprise to see voltage drop. Maybe drive a little blue chineese relay 10A at 5v level is better, who said an overkill? Yes but always cheap.
Better solution will use small mosfet p like CEM4943 (always chineese), with this crappy switch to drive it.

6 years ago

what do you think of the included power supply?
assuming that it will sneak through customs despite missing CE,
shouldn’t it be considered as electrical shock or fire hazard?

6 years ago

On the same topic, I toggled a 5v relay via the DTR pin of a cp2102 usb-serial adaptor, while the tx-r-gnd were still used for the serial console of a bananapi:


I plan to replace it with an esp8266, since the serial can be exported via TCP.

Weller PCB manufacturer