摘要 |
PURPOSE: An apparatus for compensating time error in a GSM terminal and a method therefor are provided to obtain very accurate time in spite of using a low-priced crystal by compensating a count error of a low frequency clock signal resulted from a change in an external condition(temperature, voltage) by using a very accurate high frequency clock signal. CONSTITUTION: A CPU(100) displays time information on an LCD and controls an overall time compensating operation. A scaling unit(110) scales a 13MHz high frequency clock signal. A frequency counter unit(120) counts a 65 MHz high frequency clock signal outputted from the scaling unit(110) and a currently inputted low frequency clock signal. A time compensating unit(130) compares counts values(Hc,Lc) outputted from the frequency counter unit(120) and calculates a compensation count value of the low frequency clock signal. An RTC(Real Time Clock) circuit(140) compensates a count value of the low frequency clock signal according to the count compensation value outputted from the time compensating unit(130). The high frequency signal counter(21) counts the high frequency signal outputted from the scaling unit(110) for a predetermined time period. A low frequency counter(22) counts the currently inputted low frequency signal. A frequency ratio calculating unit(31) compares the count values(Hc,Lc) and calculates a frequency ratio of the low frequency clock signal to the high frequency clock signal. A low frequency signal generator(32) calculates the currently inputted low frequency clock signal according to the obtained frequency ratio. A compensation value calculating unit(33) compares the calculated count value of the low frequency clock signal with an ideal count value of the low frequency clock signal and calculates a count compensation value. A compensation value updating unit(34) updates a count compensation value and transfers it to the RTC circuit(140) at certain periods.
|