Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
06/03/04 06:32
Read: times


 
#71623 - RE: Power outage logger
Responding to: ???'s previous message
I need to power the system in case of power outage,I was thinking of a capacitor which could power the Uc till the data was logged.

I was thinking of using a 89c51 /52 with 16x2 LCD display



Hallo Kashyap,

as someone told, that power mains voltage can be cut for longer periods, a capacitor will not do the job. Ok, you can store the time of occurence into your non voltile memory, but if mains voltage is still cut in the moment, where you want to read the data out, what then? Waiting until mains is available again? What, when you must wait several hours??

I think, your data logger should have an emergency supply voltage, which is able to deliver the needed supply current, when you want to read out logged data, while mains voltage is absent. I would proceed with the following circuit:



It was not my intention to design something ultra extravagant, only using latest chips, but to use standard parts, which should be easily available. Also, circuit was not designed to provide the least possible supply current, in the absence of mains voltage, because, it's the purpose to monitor the mains voltage, means, the circuit will see the mains voltage every day, or am I wrong?

I would start with a lead-acid battery of 12V and about 2.5Ah capacitiy. In order not to overcharge the battery, charging is done by applying a constant voltage. At 25°C 2.3V per cell is maximum voltage, which can be applied for longer periods. But for +40°C, which is a much more probable temperature in your environment (as Raghunathan told me once...), only 2.2V per cell should be applied. So, LM317 is designed to deliver exactly 13.2V, if no load current is flowing.

1.2Ohm resistor provides a current limiting: If at battery a voltage of 13V drops, about 30mA current will flow. If 12V drops, about 100mA will flow, if 11V drops, about 180mA will flow, if 10V drops, about 260mA will flow and if 9V drops, about 330mA will flow. Maximum current is about 1.0A.
This current limiting is necessary, because transformer should remain handy, and it helps to keep the dissipated power under control.

A word about current consumption of your 89C52 board: From the above currents you can see, that current consumption of your board should not exceed about 30...40mA, or so, if mains off situation can last many hours a day. Otherwise the bilance becomes negative. As rule of thumb: If you take 1Ah from baterry you must recharge 1.2Ah. From this you can estimate allowed duty cycle of mains on/off and supply current of your 89C52 board.

BC337 at LM317 is used to keep the discharging current through this regulator minimal, while mains voltage is off.
This circuit can also be supplied by the voltage of a solar panel. In order to prevent the individual sources of supply voltage to load each othe,r these many diodes (1N5404) are needed.

A battery must never be totally discharged. This cirucuit does not accomplish this totally. But it helps to prevent this case as much as possible. To do this, the load (your 89C52 board, of course) is switched off by the help of BS250 (P-channel enhancement MOSFET), whenever battery voltage drops below 9V. This is checked by the help of comparator TLC352.
In order to prevent oscillation, a threshold was introduced, means the load is connected to battery again, only, when battery voltage has rised up to about 11V.
Of course, you can improve the current consumption by chosing a better zener diode, needing less bias current, than LM336-2.5. Also, instead of 7805 a regulator needing less idle current could be used. But again, the intention was to use standard parts, keeping in mind, that mains voltage isn't cut off for more than a day, or so.

'Mains-off' signal for 89C52 is fabricated by the help of an additional diode + capacitor combination. This is helpful, because big 1000µF storage capacitor would need more than a minute to get totally discharged by the according BC337 circuitry. If this uncertainty does not matter, you can connect the 15kOhm resistor directly to plus pole of 1000µF capacitor. Then, omit the diode and the 10µF capacitor.

To adjust the cirucit, remove the battery, measure the voltage between the point, where the plus terminal of battery will be connected to, and ground. Adjust to excat 13.2V.


Some hints:

1. 500Ohm trimmer must be a very good one. The wiper must never loose its connection to substrate! So, only an expensive cermet trimmer (multiturn) is allowed to be used!!

2. Battery must not inserted with wrong polarity!! So, battery should be mounted into same chassis, where 89C52 board is installed, so that nobody can eroneously misconnect it. Mark the poalrity of terminal in such a way, that no misinterpretation can result.

3. In certain situations, heat disspation of LM317 and 7805 can be rather high. So, very good cooling is needed. Especially in your environment...

4. Every battery can be dangerous! Do wear saftey classes when experimenting with these parts!! If the battery becomes hot suddenly, remove all connections and check what you are doing right now.

Kai

List of 35 messages in thread
TopicAuthorDate
Power outage logger            01/01/70 00:00      
   RE: Power outage logger            01/01/70 00:00      
   RE: Power outage logger            01/01/70 00:00      
   RE: Power outage logger            01/01/70 00:00      
   RE: Power outage logger            01/01/70 00:00      
      RE: Power outage logger            01/01/70 00:00      
      RE: Power outage logger            01/01/70 00:00      
   RE: Power outage logger            01/01/70 00:00      
   RE: Power outage logger            01/01/70 00:00      
      RE: Power outage logger            01/01/70 00:00      
         RE: Power outage logger            01/01/70 00:00      
            RE: Power outage logger            01/01/70 00:00      
               RE: correction            01/01/70 00:00      
            RE: Relay            01/01/70 00:00      
               RE: Relay            01/01/70 00:00      
         RE: RTC Crystal            01/01/70 00:00      
      Battery operated devices            01/01/70 00:00      
         RE: Battery operated devices            01/01/70 00:00      
   RE: Power outage logger            01/01/70 00:00      
      RE: Power outage logger            01/01/70 00:00      
         RE: Power outage logger            01/01/70 00:00      
            RE: Power outage logger            01/01/70 00:00      
            RE: Power outage logger            01/01/70 00:00      
            RE: Power outage logger - Jez            01/01/70 00:00      
         RE: Power outage logger            01/01/70 00:00      
            RE: Power Backup            01/01/70 00:00      
   RE: LCD            01/01/70 00:00      
      Okay What I have done            01/01/70 00:00      
         RE: Okay What I have done            01/01/70 00:00      
            Cool Michael !            01/01/70 00:00      
               RE: Cool Michael !            01/01/70 00:00      
               RE: Cool Michael !            01/01/70 00:00      
            RE: Okay What I have done            01/01/70 00:00      
         Proceed...            01/01/70 00:00      
   RE: Power outage logger            01/01/70 00:00      

Back to Subject List