Introduction: Automatic Phone Charging Disconnector

You can put your phone on charge and sleep peacefully!

This device will disconnect the charging after a period of time that you prefer!

May be 1 hour, 2 hour or some suitable time period!!!

Check out the attached YouTube video for full clarity!

I used a designed PCB board for the project purpose (though it is not compulsory).
I designed and got my board manufactured from JLCPCB, a leading Chinese PCB making company!

And please make sure you subscribe my channel Nova Technologies on YouTube to stay tuned with more videos!!!

Precaution: Before you start working on this project make sure you disconnect all your devices and extension sockets from house electric supply. or just switch off all the power supplies first in order to avoid electric shock!!!

Step 1: Things You Need

Here are the things you need:

1. Phone

2. Charger of the Phone

3. Extension Socket

4. Arduino board

5. Relay module (one channel relay is enough)

6. Red and Green LEDs

7. Nose cutter

8. Jumper wires

9. etc.

Step 2: Operation With the Extension Socket

Before start working make sure you switch off all power supplies and unplug the devices, extensions, and any equipment you work with!

1. Open the extension socket using screw driver.

2. Select the exact socket/port where you are going to plug in the phone charger.

3. Now select the Life wire supply of the particular socket.

4. Now using nose cutter cut the Life wire in the middle.

Now you can see the two terminals of the life wire in the place where it has been cut.

5. Take two lengthy wires (that can conduct AC current) and solder each wire with each of the disconnected terminals of the life-wire.

6. Now make a small hole in the plastic cover of the extension socket and take both wires out. Now close the extension socket, tighten it using screw-driver.

Now you have an extension, closed but two wires coming outside from inside.

For more clarity you can watch the video attached!

Step 3: Connecting to Relay and LEDs to Arduino

1. Take the one channel relay.

2. In one side of the relay module, you can find the pins called "NC", "NO", and "COM".

3. Connect the two wires that are coming out of the extension socket, to the "NO" and "COM" pins of the relay module.

(You can refer the connection diagram, and the video for more clarification.)

4. Provide Vcc and Ground supply to the relay from Arduino.

5. Connect the "IN" pin of the relay to Arduino digital pin 2.

6. Take a Red and Green LED.

7. Connect the Green LED with Arduino digital pin 2 where the relay "IN" pin is connected.

8. Connect the Red LED with Arduino digital pin 3.

Find the connection diagram here: (will be updated soon)

Note: Since I used Arduino Nano, I created a PCB design for the components and got the board manufactured from

JLCPCB!

But you can just handle it with jumper wires or breadboard if you prefer!

Note: Connect 330 ohm resistors with LEDs if needed, and don't forget to ground the LEDs as well.

Step 4: Upload Coding

1. Find the link of the coding here.

Upload the coding to the Arduino board.

2. Before uploading please note these points:

In this coding the time for charging is set to be 1 hour.

A variable called "TimeUp" is holding the value.

If you want to change the time duration your phone to be charged, please convert your time duration into milliseconds and replace the value of the "TimeUp" with your value.

Now you can upload the coding.

Step 5: Final Implementation

1. Now connect the phone charger to the exact socket of the extension that you configured for the work (by cutting the life wire and connecting the terminals to the relay). Then connect the phone with the charger. Remember your extension is not provided with power at the moment.

2. Connect your arduino with the power source cable. Plug in the power source but don't switch ON now. You can connect the arduino power supply to another normal socket of the same extension where the phone charger is connected. (normally one extension has around 4 sockets).

3. Now switch on the extension.

4. If both the charger and arduino are in two sockets of the same extension, then your phone will start to charge.

5. If not, now please switch ON the Plug of the Arduino power supply. You will see your phone start charging. The Green LED also will indicate that your phone is charging.

6. Now you can sleep peacefully so that your phone will stop charging after the time duration you have mentioned in the coding. The Red LED will indicate the charging has been stopped!

(Note: While using the device take extreme care to avoid electric shock since you are playing with high voltages. Insulate all the possible wires, outlets, and whatever that has a chance of giving electric shock and handle with extreme care!)

Check out the video for more clarification. Do Subscribe my channel for more!

Good Luck!!!!