In this article we discuss a UPS circuit powered from mains supply. The backup power is provided by NimH batteries.
Figure 1 : UPS schematic
The power supply shown here is designed to provide a voltage of 3.6V and a current of up to 300mA. The circuit shown above is however limited to 100 mA due to the LP2981. The LDK130 LDO can provide current up to 500 mA. The 230V to 5V 1.5VA centre- tapped transformer T1 steps down the mains voltage to 5V AC where it is rectified by diodes D1 and D2. The capacitor C1 is used to smooth the ripple of the rectified DC voltage. The power supply contains a 3.6V NimH backup power battery which is indefinitely connected to the circuit. In the event of mains failure, the battery takes over automatically; and the output from the power supply is not interrupted. When mains is restored, the battery recharges automatically.
The power supply is designed to consume as less power as possible from the main. The low-voltage drop rectifiers and LP2981 regulator make sure that the system has minimum power dissipation.The centre-tapped transformer enables the use of only two diodes instead of four to achieve full wave rectification. At each half cycle, current flows through only one of the 2 transformer secondary windings and thus through only 1 diode at a time. This enables the rectifying circuit to have a forward voltage drop of 0.4V instead of 0.8V for a full bridge rectifier (where 2 diodes in series conduct at each half cycle) and again less power dissipation.
The backup battery enables the system to work for 30 minutes in the event of a mains failure under full load. The battery is charged at a slow rate which is usually referred as trickle charging. This allows the battery to be indefinitely connected to the charging circuit. The advantage of trickle charging is that no ‘end-of-charge’ circuitry is required since the battery will never be damage regardless to how long it is used. This means that the charging circuit is cheap and simple.
The transformer T1 produces a peak voltage (VPEAK) of 5√2 Volts and the rectifying diode has a forward voltage drop of 0.4 Volts. This reduces the incoming voltage to 6.67V. Capacitor C3 is used to bypass high frequency component from the circuit and both C2 and C3 were chosen according to the LP2981 datasheet. They also ensure stability over full load current and better performance.
Smoothing Capacitor C1
The output from the rectifier circuit is fed into the input of the LP2981 regulator and the value of the smoothing capacitor C1 will depend on the voltage needed at that input.
Figure 2. Regulator
The regulator outputs 3.8V and has a voltage drop of 200mV. So the minimum required input voltage is 4.0V. The regulator is able to respond to small fluctuation in input voltage. Therefore in this case a perfect smoothing is not essential as the regulator will produce a constant DC of 3.8V as long as the voltage from its input does not fall below 4.0V. So the ripple voltage can vary between the peak voltage of 6.67V (VOPEAK), and 4.0V.
Figure 3. Rectified waveform
The capacitor ensures that the ripple voltage never go below 4.0V and therefore provides the input of the regulator with the required voltage at all time. With the frequency of the full wave rectified supply being twice the frequency of the mains (= 100Hz) and with the load drawing a current of 0.023A, C1 is found to be 86µF. So a preferred value of 100 µF is used.
Since the battery is continuously connected to mains supply, it gets the charges used up back throughout the entire day. To ensure that the battery is fully charged at the end of a day, the total amount of charge used up must equal to amount of charge regained.
Taking into consideration the amount of charge which will be used up and the recharge rate in one day:
Amount of charge in a fully charged battery = 3600C Coulombs
Amount of charge gain during charging = charging time x Charging rate
= (23.5 x 3600 x 0.025C) Coulombs
= 2115C coulombs.
Amount of charge used up due to mains failure = [charge used by system in 30 minutes]
= ([30 x 60 x 0.300])
= 540 Coulombs.
Full battery – recharged – backup power = Full battery
3600C + 2115C – 71.4 = 3600C
C = 255 x 10-3 = 255 mAh.
So a 3.6V NiMh 280mAh battery can be used.
1. C is the capacity of the battery in Ah charging at a rate of 0.025C.
2. Full battery is the charge in a fully charge battery.
3. Recharged is the charge gained (at a rate of 0.025C) by the battery for the whole day (23.5 hours).
4. Backup power is the power required for system to run for 30 minutes in case of mains failure.
The maximum safe trickle charging rate for this kind of battery is C/40, where C represents the Amps-hour of the battery. And hence:
The current needed to trickle charge the battery is: = 0.025C
= 0.025 x 280mAh
Resistor R1 is used to draw and limit the charging current to 7.0mA.
Charging Resistor R1
Resistor R1 is connected directly to the transformer through 2 rectifier diodes and so a full wave rectified voltage is available to the charging circuit. A minimum voltage of 3.6V is required across the charging terminal to enable the battery to charge. Hence taking into account the voltage drop across the rectifier diode, the battery is charged whenever the supply voltage is above 4.0V.
To determine the value of R1 needed to draw a current of 7.0mA, the average value of voltage is needed.
The Figure 4 below shows a voltage waveform available in series with resistor R1.
Figure 4 Charging resistor waveform.
The average voltage is found by integrating the voltage waveform shown above between point P1 and point P2, which corresponds to a voltage of 4.0V, and by dividing the integral by and finally by adding that value to 4. The average voltage is found to be 5.04V and so the required resistor R1 is calculated using Ohm’s law.
So a preferred value of 732Ω is used.
Automatic switching of supply
D4 provides a one-way path that allows the incoming current to pass during mains failure while it prevents current from the regulator finding its way to the battery terminals under normal conditions. On the other hand D3 prevents current from battery flowing into the regulator pin.
The terminal voltage of a fully charge battery is 3.6 Volts and the voltage from the regulator is 3.8 Volts. Taking into account the voltage drop across the diodes D3 and D4, the voltage from the regulator and the battery are 3.4V and 3.2V respectively. Since the regulator pin is at higher potential, no current will flow from the battery. However when mains supply is unavailable, the regulator voltage will drop from 3.4V to 0. As that voltage gets lower than 3.2V, current will start flowing from the battery and will continue to provide supply without any power interruption. However the supply will drop from 3.4V to 3.2V under mains failure.
When the mains come back on, the regulator voltage will rise to 3.4V again; and being higher in potential than the battery, it will prevent current from flowing from battery. This difference in potentials allows the circuit to automatically switch between the two supplies.
Happy tinkering. Feel free to comment and to contact us on firstname.lastname@example.org
If you spot any error or discrepancy, feel free to let us know 🙂