Raspberry Pi UPS Backup Using 2 Diode Switch





Raspberry pi is powered using a 5 Volts Buck Converter. 

The Buck Converter needs an Input Voltage more than it's Output Voltage which, in this case is 5 Volts.

First i powered it up with only a 12 Volts Output from an AC-DC power-supply.

Then I used a 9.6 Volts Ni-Cd Battery which was fully charged and at a Voltage above 10 Volts.

After making sure that it works I used Two Silicon Diodes (A610)  for Switching the Buck Converter's Input from the 12 Volts, coming from the Power Supply Unit, TO the 9.6 Volts coming from the Ni-Cd Battery and without any Interruptions.So, when the AC power goes out the Buck Converter will automatically be powered by the Battery and the Switch happens almost instantly.

As shown in the picture above the Ground is common for all as Negative terminals on the Buck Converter, the 12 V Output of the AC-DC P.S.U. and the Ni-Cd Battery are all connected together. 

The Positive terminal on the 12 Volt Output from the P.S.U. connects to the Anode of the Diode 2 and the Cathode of the Diode 2 connects to the Positive terminal on the Input of the Buck Converter.  At the same time, the Positive terminal on the 9.6 V Ni-Cd Battery is connected to the Anode of the Diode 1 and the Cathode of the Diode 1 is connected to the Positive terminal on the Input of the Buck Converter. 

Both Cathode terminals of both Diodes are joined together at the Buck Converters Input. But it all works because of the way the diode works. 

Because, the 12 Volts coming from the AC-DC Power Supply, is Higher than the 9.6 Volts coming from the Battery, the current will flow from the Output of AC-DC Power Supply to the Anode of the Diode 2 and the Diode 2 will get "Forward Biased" then it will flow through the Diode 2 Cathode terminal to BOTH ,the Input of the Buck Converter and the Cathode of the Diode 1.

The Current that goes to the Input of the Buck Converter will power the Buck Converter and the Raspberry and the Current that flows to the Cathode of the Diode 1 will "Reverse Bias" the Diode 1 there-by preventing any flow of current from the Battery. 

This is only possible when the Battery Voltage is lower than the Power Supply's output voltage .

When the AC power goes out or is turned off, the Voltage from the Output of the AC-DC Power Supply will drop and as soon as it drops lower than the Battery Voltage the Diode 1 gets "Forward Biased" because now the potential is higher on it's Anode and the Current will flow from the Battery to BOTH, the Input of the Buck Converter and the Cathode of the Diode 2. 

It will power the Buck Converter and the Rpi and will "Reverse bias" the Diode 2.

All of this happens almost instantly and the Pi works without any interruptions in it's 5 Volts Input. 

No comments:

Post a Comment