
Micrel, Inc.
XCOtune Procedure Example
A procedure such as the algorithm given below can be
called during production (storing the calibrated XCO_tune
value), at regular intervals, or implemented in the
communication protocol when the frequency has changed.
The MICRF507 measures the frequency offset between
the demodulated signal and the LO, and a micro-controller
programs the XCO_tune bits to tune the XCO so the LO
frequency is equal to received carrier frequency.
MICRF507
Registers properly set for reception;
LOOP:
XCO_Step = XCO_Step/2;
If (XCO_Sign == POS) then
// If POS then increase LO frequency:
{XCO_present = XCO_present - XCO_Step}
Else
Procedure description:
A transmitter is assumed to be
// If NEG then decrease LO frequency:
sending a 1010… pattern at the correct frequency and bit
rate. The FEE is enabled (FEEC[1:0] = 11) and the
number P of bit periods used in the measurement is 8 or
16. Only the sign of FEE is used.
;
{XCO_present = XCO_present + XCO_Step}
Objective: The best XCO_tune value (giving the lowest
IFEEI). The desired frequency of the receiver’s PLL is
midway between the “0” and “1” frequencies.
Local variables:
XCO_Present: (5-bit) holds current value in XCO_tune
field
XCO_Step: (4-bit) holds amount by which XCO_tune will
be incremented or decremented
XCO_Sign: (1 bit) has a value of either POS or NEG,
determining respectively whether XCOtune is to be
incremented or decremented (reducing XCOtune
increases LO frequency)
XCO_tune_bits is a buffer, which is written to the XCOtune
field when ProgramRFChip is called.
XCO TUNE PROCEDURE
Initialization:
XCO_Present = 16;
XCO_Step = 16;
XCO_Sign = NEG;
XCO_tune_bits = XCO_Present;
ProgramRFChip;
Wait for > P bit periods;
Read FEE;
If (FEE > 0?) then
{XCO_Sign = POS}
else
{XCO_Sign = NEG} // negative or 0
;
If (XCO_Step > 1) then
{Branch to LOOP}
Else
{If(XCO_Sign == POS) then
{XCO_Present = XCO_Present – 1;
Return (XCO_Present)}; \ done
}
;
October 2, 2013
27
Revision 2.2