rtc selection

13
Maxim/Dallas > App Notes > REAL-TIME CLOCKS Keywords: Battery, cell, super cap, supercap, rechargeable Apr 26, 2006 APPLICATION NOTE 3816 Selecting a Backup Source for Real-Time Clocks Abstract: Most Dallas Semiconductor real-time clocks (RTCs) include a supply input for a backup power source. This alternate supply source allows the RTC to maintain the current time and date while the main power source is absent. This application note discusses the various types of alternate supplies that can be used, as well as some of the criteria a designer should consider when selecting a backup source. Introduction The first Dallas Semiconductor RTCs were designed so that a backup source, such as a primary (nonrechargeable) lithium coin cell, could be used as the backup supply. Since then, Dallas has introduced additional RTCs with built-in trickle chargers. Changes that affect system requirements since the first RTCs were introduced include the shift to IR reflow in manufacturing and restrictions on transportation and disposal of lithium cells. The following paragraphs discuss backup techniques and the advantages and limitations of commonly used backup supply sources. Backup Supply Operation Early Dallas Semiconductor RTCs had a relatively simple voltage-comparator circuit to monitor V CC and switch between the V CC and V BAT supplies. The DS1307, for example, uses a comparator and a voltage divider to switch to V BAT when V CC drops below approximately 1.25 times the voltage on V BAT . Other RTCs, such as the DS1305/ DS1306, switch when V CC drops below the V BAT input voltage. When using these devices, care must be taken to ensure that the voltage on V BAT never rises high enough to cause the device to inadvertently switch over to V BAT while V CC is at the normal operating voltage. An external charging circuit must limit the maximum charging voltage to prevent such an occurrence. Newer Dallas RTCs, which are designed to allow operation whether V CC is above or below the voltage on V BAT , use an internal bandgap voltage reference to determine when V CC is too low for normal operation. The following table lists the common supply technologies used for backup power. The table lists key parameters that affect selection. The paragraphs following the table discuss each technology and their advantages and drawbacks. Table 1. Common Backup Supply Sources and Key Selection Criteria Technology Operating Temperature (°C) PC Board Attachment Self- Discharge Rate Disposal/ Transportation Restrictions Charging Circuit/ Cycles Backup Time Primary Lithium -30 to +80 Wave solder 1 Low High N/A Long Capacitor -40 to +85 SMT High Low Simple/ unlimited Short

Upload: madhuvariar

Post on 11-Apr-2015

862 views

Category:

Documents


6 download

DESCRIPTION

Real Time clock chip from Maxim _ics use Microcontroller and LCD Or LED displays to display time date and month yearetceven u can convert it to a data logger with date and time

TRANSCRIPT

Page 1: RTC selection

Maxim/Dallas > App Notes > REAL-TIME CLOCKS

Keywords: Battery, cell, super cap, supercap, rechargeable Apr 26, 2006

APPLICATION NOTE 3816

Selecting a Backup Source for Real-Time Clocks

Abstract: Most Dallas Semiconductor real-time clocks (RTCs) include a supply input for a backup power source. This alternate supply source allows the RTC to maintain the current time and date while the main power source is absent. This application note discusses the various types of alternate supplies that can be used, as well as some of the criteria a designer should consider when selecting a backup source.

Introduction

The first Dallas Semiconductor RTCs were designed so that a backup source, such as a primary (nonrechargeable) lithium coin cell, could be used as the backup supply. Since then, Dallas has introduced additional RTCs with built-in trickle chargers. Changes that affect system requirements since the first RTCs were introduced include the shift to IR reflow in manufacturing and restrictions on transportation and disposal of lithium cells. The following paragraphs discuss backup techniques and the advantages and limitations of commonly used backup supply sources.

Backup Supply Operation

Early Dallas Semiconductor RTCs had a relatively simple voltage-comparator circuit to monitor VCC and switch

between the VCC and VBAT supplies. The DS1307, for example, uses a comparator and a voltage divider to switch

to VBAT when VCC drops below approximately 1.25 times the voltage on VBAT. Other RTCs, such as the DS1305/

DS1306, switch when VCC drops below the VBAT input voltage. When using these devices, care must be taken to

ensure that the voltage on VBAT never rises high enough to cause the device to inadvertently switch over to VBAT

while VCC is at the normal operating voltage. An external charging circuit must limit the maximum charging

voltage to prevent such an occurrence. Newer Dallas RTCs, which are designed to allow operation whether VCC is

above or below the voltage on VBAT, use an internal bandgap voltage reference to determine when VCC is too low

for normal operation.

The following table lists the common supply technologies used for backup power. The table lists key parameters that affect selection. The paragraphs following the table discuss each technology and their advantages and drawbacks.

Table 1. Common Backup Supply Sources and Key Selection Criteria

TechnologyOperating Temperature (°C)

PC Board Attachment

Self-Discharge Rate

Disposal/Transportation Restrictions

Charging Circuit/Cycles

Backup Time

Primary Lithium -30 to +80 Wave solder1 Low High N/A Long

Capacitor -40 to +85 SMT High Low Simple/unlimited Short

madhu
Note
See page 5 Trickle Charging
Page 2: RTC selection

Rechargeable (NiCd/NiMh) 0 to +402 Hand solder3 Medium Medium Simple/ 500 Short

Reflowable ML -20 to +60 SMT Low High Voltage 12 - > 1000 Medium4

1. Primary lithium cells may be wave soldered as long as the cell temperature does not exceed +85°C. Cells may be placed in a holder or hand soldered after reflow (tabbed cells).

2. Ambient temperature during charging. The allowed ambient temperature during discharge may be higher.

3. Batteries may be placed in a holder or hand soldered after reflow (tabbed batteries). 4. Total backup time is dependent upon the depth of discharge between each charging cycle.

Lithium Primary (BR and CR) Cells

Primary lithium coin cells are commonly used for RTC and memory backup. Lithium cells have a high energy density, thus taking up a small amount of room on a PC board. Lithium cells cannot withstand IR reflow, so the cell must either be soldered on after reflow or inserted in a holder, thus increasing cost. Self-discharge near room temperature and below is typically less than 1% per year. At temperatures above about +60°C, self-discharge quickly increases. Recent regulations limit the transportation of lithium primary cells aboard passenger aircraft. Other regulations govern disposal of the cells at end of life, in some cases placing the burden on the manufacturer.

Lithium primary cells are usually sized to power the RTC for the expected life of the product. To calculate cell life based upon the current draw of the RTC, divide the cell capacity in ampere-hours by the timekeeping current draw of the RTC. For example, the timekeeping current of the DS1307 RTC (with the square-wave output off) is specified as 500nA maximum. A BR1225 lithium primary cell is rated at 48mAh. Therefore, (0.048 / 500e) - 9 = 96,000 hours, or 4,000 days (almost 11 years). For additional information regarding calculating cell life, please refer to Application Note 505, Lithium Coin-Cell Batteries: Predicting an Application Lifetime.

The following is a list of links to some lithium coin-cell manufacturer web sites: Panasonic: OEM Batteries Sanyo: Industrial Batteries Rayvac: Specifications and Product Guides Rayvac: Technical/OEM News

Capacitors

Large low-leakage capacitors, sometimes called supercaps, are sometimes used for backup. The advantages of a capacitor over primary lithium cells include the ability to IR reflow the capacitor and fewer regulations concerning shipment and disposal. However, capacitors require a charging circuit, and provide backup operation for a relatively short time. Capacity may decrease with use, especially at higher operating temperatures.

For additional information about capacitors for backup and how to calculate the backup time for a given capacitor size, please refer to Application Note 3517, Estimating Super Capacitor Backup Time on Trickle-Charger Real-Time Clocks. To determine backup time, please refer to the online Super Capacitor Calculator (For Trickle Charger RTCs).

The following is a list of links to some capacitor manufacturer web sites: Panasonic: Gold Capacitors NEC TOKIN: Super Capacitors Kanthal Global: Capacitors Cooper Electronic Technologies: Supercapacitors

madhu
Note
See Page 5 Trickle charging
Page 3: RTC selection

NiMH and NiCd Batteries

Rechargeable NiMH and NiCd batteries have a relatively high self-discharge rate of about 10% per month for NiCd and 20% per month for NiMH at room temperature. The typical operating temperature range (charging) is approximately 0°C to +40°C. NiMH and NiCd batteries must be hand-soldered or placed in a battery holder after the PC board has gone through reflow. The batteries may be charged using a relatively simple current-limited charging circuit. Overcharging may reduce the life of the battery. Disposal at end of life may be regulated in some regions. NiMH and NiCd battery life is limited by the number of charge/discharge cycles.

The following is a list of links to some rechargeable battery manufacturer web sites: Panasonic: OEM Batteries Sanyo: Industrial Batteries

Lithium Secondary (ML) Cells

ML cells require a regulated-voltage-charging source. The maximum voltage must be closely regulated or permanent damage will occur, while too low a voltage results in incomplete charging. ML cells are subject to the same transportation and disposal regulations as lithium primary cells. The DS12R885/DS12R887 RTCs include a charger with the required voltage and current limits on-chip. The DS12R887 RTC integrates the ML cell in a BGA package.

One issue with secondary cells is the number of charge/discharge cycles that they can withstand during the normal service life. For ML cells, the number of charging cycles is directly related to the depth of discharge as detailed in Application Note 3779, Calculating ML Cell Life for an RTC Backup Operation. An on-line Manganese Lithium Rechargeable Cell Lifetime Calculator (For Constant-Voltage Trickle Charger RTCs) is available for determining ML cell lifetime.

The following is a list of links to some rechargeable lithium ML coin cell manufacturer web sites: Panasonic: OEM Batteries Sanyo: Industrial Batteries

Conclusion

No single RTC backup power source is perfect for every application. The designer must use such criteria as expected system lifetime, governmental regulations, and manufacturing requirements to select a backup supply that is best suited for the application. Using such criteria, the system designer can select a suitable RTC backup supply technology.

Application Note 3816: http://www.maxim-ic.com/an3816 More Information For technical questions and support: http://www.maxim-ic.com/support For samples: http://www.maxim-ic.com/samples Other questions and comments: http://www.maxim-ic.com/contact Related Parts

DS12885: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS12R885: QuickView -- Full (PDF) Data Sheet -- Free Samples

madhu
Note
See Trickle Charging also on next ... page 5
Page 4: RTC selection

DS12R885: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1302: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1305: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1306: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1307: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1315: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1318: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1337: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1337: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1338: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1338: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1338: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1339: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1339: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1340: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1340: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1374: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1390: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1391: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1392: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1393: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS14285: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1500: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1501: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1558: QuickView -- Full (PDF) Data Sheet

DS1670: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1672: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1673: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1677: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1678: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS1685: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS17285: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS17485: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS17885: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS3231: QuickView -- Full (PDF) Data Sheet

DS3232: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS3234: QuickView -- Full (PDF) Data Sheet -- Free Samples

DS32KHZ: QuickView -- Full (PDF) Data Sheet -- Free Samples

Page 5: RTC selection

1 of 9 052402

DESCRIPTION The Dallas Semiconductor/Maxim real-time clock (RTC) family contains a number of parts within an integrated trickle-charging circuit. This application note describes the operation of the DS1302 trickle charger. Most of the data in this note can be applied to other Dallas RTC trickle chargers, with a few circuit-specific changes. Figure 1. DS1302 PROGRAMMABLE TRICKLE CHARGER

Application Note 82Using the Dallas Trickle

Charge Timekeeper www.maxim-ic.com

madhu
Highlight
Page 6: RTC selection

AN82

2 of 9

TRICKLE CHARGER The trickle charge circuit is shown in Figure 1 along with the trickle charge register. To enable the trickle charger, the desired path through the circuit must be selected and the appropriate pattern written to the trickle charge register. The trickle charge select (TCS) bits (bits 4 to 7) control the selection of the trickle charger. In order to prevent accidental enabling, only a pattern of 1010 enables the trickle charger. All other patterns disable the trickle charger. The DS1302 powers up with the trickle charger disabled. The diode select (DS) bits (bits 2 to 3) select whether one diode or two diodes are connected between VCC2

and VCC1. If DS is 01, one diode is selected or if DS is 10, two diodes are selected. If DS is 00 or 11 the trickle charger is disabled independently of TCS. The RS bits (bits 0 to 1) select the resistor that is connected between VCC2 and VCC1. The resistor selected by the resistor select (RS) bits is as follows:

RS BITS RESISTOR TYPICAL VALUE 00 None None 01 R1 2kΩ 10 R2 4kΩ 11 R3 8kΩ

If RS is 00 the trickle charger is disabled independently of TCS. The user determines diode and resistor selection according to the maximum current desired for battery or super cap charging. The maximum charging current can be calculated as illustrated in the following example. Assume that a system power supply of 5V is applied to VCC2a and a super cap is connected to VCC1. Also, assume that the trickle charger has been enabled with one diode and resistor R1 between VCC2

and VCC1. The maximum current IMAX would, therefore, be calculated as follows:

IMAX = (5.0V - diode drop) / R1 ~(5.0V–0.7V) / 2kΩ

~2.2mA

Obviously, as the super cap charges, the voltage drop between VCC2 and VCC1 decreased and, therefore, the charge current decreases. See curves in Trickle Charge Characteristics. POWER CONTROL The DS1302 can be powered in several different ways. The first method, shown in Figure 2, illustrates the DS1302 being supplied by only one power supply. In Figure 2a, the power supply is connected to VCC2 (pin 1) and in Figure 2b the power supply is connected to VCC1 (pin 8). In each case, the unused power pin, VCC1 or VCC2, is grounded. The second method, Figure 3, illustrates the DS1302 being backed up using a nonrechargeable battery connected to VCC1. In these two cases the trickle charge circuit has been disabled. In the final case, Figure 4, the DS1302 is being backed up by connecting a super cap, Figure 4a, or a rechargeable battery, Figure 4b, to VCC1. In this case, the trickle charge circuit has been enabled.

Page 7: RTC selection

AN82

3 of 9

Figures 2a and 2b. SINGLE POWER SUPPLY OPTION

Figure 3. NONRECHARGABLE BATTERY BACKUP

Figures 4a and 4b. SUPER CAP OR RECHARGABLE BATTERY BACKUP

Page 8: RTC selection

AN82

4 of 9

TRICKLE CHARGE CHARACTERISTICS Charging the Super Cap The maximum current, IMAX, required by the trickle charge circuit can be calculated by inserting the correct values selected in the trickle charge register into the following equation

IMAX = (VCC2 - diode drop) / R Table 1 contains the values of IMAX for VCC2 values of 4.5V, 5.0V, and 5.5V; 1 diode drop and 2 diode drops; resistor values of 2000Ω, 4000Ω and 8000Ω. Also, the charging current can be modeled as a function of charge time. Both the super cap voltage and charging current as a function of time are represented in Figure 5. The equation to model the super cap voltage as a function of time is

V(t) = VMAX [1 - e (-t / RC)]

where

V(t) = Super Cap Voltage VMAX = (VCC2 - n Diode Drops), n = 1, 2 R = Internal Trickle-Charge Resistor C = Super Cap Capacitance

The time needed to charge the super cap to 95% of VMAX is given in Table 2. Note that the time required to charge the super cap to 95% of the value of VMAX is independent of the value of VMAX. The equation, which models the charging current as a function of time, is given as

I(t) = VMAX / R x e (-t / RC)

where

I(t) = Charging Current VMAX = (VCC2 - n Diode Drops), n = 1, 2 R = Internal Trickle-Charge Resistor C = Super Cap Capacitance

Page 9: RTC selection

AN82

5 of 9

Discharging the Super Cap When modeling the DS1302 for the time to discharge the super cap, the DS1302 characterization data was used to observe that the ICC1T, timekeeping current through VCC1, was linear. This implies that it is proper to represent the DS1302 as a resistive load, RL, through which the super cap is discharged. Using the data sheet spec of ICC1T max of 0.3µA at 2.0 VCC1 gives a value for RL of 6.7MΩ. Then the equation modeling the discharging of the super cap is given by

V(t) = VMAX x e(-t / RL

C) where

V(t) = Super Cap Voltage VMAX = (VCC2 - n Diode Drops), n = 1, 2 RL = DS1302 Load Resistance C = Super Cap Capacitance

The calculated values for the time required to discharge the super cap to 2V are given in Table 3 and a sample of the super cap voltage as a function of discharge time is given in Figure 6. Figure 7 shows the typical ICC1T current versus voltage at +25°C.

Page 10: RTC selection

AN82

6 of 9

Table 1. CALCULATED VALUES OF IMAX

2000Ω 4000Ω 8000Ω VCC2 (V) 1 diode 2 diodes 1 diode 2 diodes 1 diode 2 diodes

UNITS

4.5 1.90 1.55 0.95 0.78 0.48 0.39 mA 5.0 2.15 1.80 1.08 0.90 0.54 0.45 mA 5.5 2.40 2.05 1.20 1.03 0.60 0.51 mA

Table 2. CHARGING TIME FOR SUPER CAP TO 95% OF VMAX

CHARGE TIME 2000Ω 4000Ω 8000Ω UNITS Super Cap = 0.047 4.7 9.4 18.8 minutes Super Cap = 0.47F 46.9 93.9 187.7 minutes Super Cap = 1.5F 149.8 299.6 599.2 minutes

Table 3. SUPER CAP DISCHARGE TIME TO 2V

0.047F 0.47F 1.5F VCC2 (V) 1 diode 2 diodes 1 diode 2 diodes 1 diode 2 diodes

UNITS

4.5 69.8 47.7 698.3 476.8 2228.7 1521.7 hours 5.0 83.3 63.9 832.8 639.5 2657.9 2040.9 hours 5.5 95.2 78.1 952.5 780.9 3039.8 2492.5 hours

Page 11: RTC selection

AN82

7 of 9

Figure 5. SUPER CAP CHARGING CHARACTERISTICS

Ch

arg

e V

olt

age

(V)

Page 12: RTC selection

AN82

8 of 9

Figure 6. SUPER CAP DISCHARGING CHARACTERISTICS

Page 13: RTC selection

AN82

9 of 9

Figure 7. DS1302 AVERAGE ICC1T at +25°C

0

50

100

150

200

250

300

350

400

2 2.5 3 3.5 4 4.5 5

VCC1 (V)

average