How to add an inline cord switch onto the cable of a USB powered device
Some time ago, I shared a post of how to make your own USB powered LED light. If you follow that post, you will be able to make your own USB powered LED light that can be attached to a USB 2.0 power adapter on your wall socket. When you turn on your wall socket, the lights will turn on. After you are done with using your light, you can turn off your wall socket to turn off the lights.
Sounds like common sense right?
However, your wall socket plug may be too far to reach at your convenience. In such a situation, you may want to add a switch onto the cable of your USB powered device.
Given that, this post discusses how we can add a switch to a 5V USB wire. In this post, I will use a white inline cord switch as an example to show how we can add an inline cord switch to a 5V USB wire.
Parts and tools
Here are some parts and tools that can help you add an inline cord switch onto the cable of a USB powered device:
- 2 conductor cable
- Inline cord switch
- Soldering iron
- Automatic wire stripping tool
- Scissors
- Solder Wire
Steps to add the inline cord switch onto the cable
Once you have the parts and tools in place, you are ready to add the inline cord switch onto your cable.
1. Strip the outer jack of the cable to add the inline cord switch
First, locate the part of the 2 conductor cable that you wish to add the inline cord switch to.
After that, use the automatic wire stripping tool to help you create the opening.
Once you have slitted the outer jacket of the cable, use your hands to slowly pull the outer jacket of the cable while keeping the red and black jackets intact. When the red and black jackets are intact, we will not break the wires easily while we pull the outer jacket apart.
2. Add the inline cord switch to the stripped section of the cable
Once you have created a sizeable opening for the inline cord switch, you can tuck the red and black wires into the switch, aligning the red one with the metal conductors on the switch. Since the red wire is designated to carry power to the USB powered device, we align it with the metal conductor. If you use other type of cables with different colors, then you will want to ensure that the wire carrying power to the USB powered device is aligned to the metal conductor.
After that, you can cut the red wire and strip the outer jacket to expose some wires. After that, coil the exposed wires to the two ends of the metal conductors on the switch.
In order to securely attached the red wires to the metal conductors, solder the red wires onto the metal conductors.
After that, put on the switch cover and you are done with adding the inline cord switch to your 5V USB wire.