A method of searching for a predefined code in a bit stream, the method comprising
initiating a first search for correlation of the bit stream with a reference code
applied to the bit stream at a first plurality of different times according to
a first resolution to produce a first set of correlation values and associated
times. Then a second search is initiated for correlation of the bit stream with
the reference code applied to the bit stream at a second plurality of different
times to produce a second set of correlation values and associated times, the reference
code being offset in time from a maximal correlation value of the first set such
that the reference code is applied to the bit stream at times other than times
of the first plurality. Then, out of the first and the second sets a maximal correlation
value is selected for use in calculating a strength of the predefined code in the
bit stream.