GSM clock and phones

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/baseband-devel@lists.osmocom.org/.

Sylvain Munaut 246tnt at gmail.com
Thu Jul 12 14:01:46 UTC 2012


Hi,

> When launching a local BTS (like with openbts on usrp or similar), one
> needs to feed the BTS with a precise clock or a reference clock,
> depending on the hardware. This step is needed because phones need a
> precise clock from the BTS, otherwise they don't camp. Is that
> correct?

Yes it needs a precise clock to work reliably. But it's not that the
phone will "reject" the BTS, it just won't find it at all ...


> If yes, my question is: how can a phone determine that the clock given
> by the network is precise enough? I'm a bit confused: how can the
> phone say that's not good, if it doesn't have a precise clock itself?

The phone doesn't have a precise clock, it has a pretty crappy cheap
one often, let's say about 20 ppm. But once it find a GSM base
station, it can tune its clock (because it's a VCXO Voltage Controlle
Xtal Oscillator) and align it to match the one of the network.

Now there are two distinct case that happens:

1) First phone power on / First sync

When you first turn on your phone it will try to find a BTS. It will
often try the last ARFCN that was used (it's written on the SIM).
During this initial acquisition, the phone uses a large frequency
error window like ~ 20 kHz for the calypso IIRC because it knows that
its own clock is currently pretty bad.

2) Funrther sync / scan

Once the phone has locked to at least one BTS, it has aligned its
clocked to it and so it knows that its own clock became fairely good
and from that point on, it will use a smaller frequency error window (
like ~ 2 kHz ) this will make the scan faster and avoid false
positives.


So as you see it's possible that a bad BTS clock would still be found
by accident if its clock happens to deviate in the same direction as
the phone xtal and if it's found during the initial scan. And this can
also lead to situation where the phone only sees either the official
networks  _or_ the "custom" network but not both depending on which it
found first ...


Cheers,

    Sylvain




More information about the baseband-devel mailing list