annotate doc/Rx-cal-theory @ 65:e7b9a9903f14

doc/Rx-cal-theory: typo fix
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 28 May 2017 05:10:32 +0000
parents 131abadbd74d
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
63
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 The incoming radio signal from the antenna passes through a chain of amplifiers
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 before it reaches the Calypso DSP, and the dBm power measurement reported by the
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 latter is significantly greater than the actual power level at the antenna
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 connector. The mobile station firmware needs to be able to determine the actual
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 input level from the DSP's power measurement (not only for reporting purposes,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 but also to select the proper AGC setting), hence it needs to know the
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 difference in dB between the DSP's power measurement and the input signal level
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 in dBm. For this purpose the firmware maintains a constant called GMagic,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 defined as:
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 GMagic = PM - IL - AGC
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 where PM is the DSP's power measurement in notional dBm, IL is the input level
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 in actual dBm, and AGC is the AGC programmable gain setting in dB. GMagic is
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 the sum of all amplifier gains and insertion losses along the Rx signal path,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 and is on the order of about 100 dB, although the fw reckons it in half-dB
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 units.
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 Some Calypso device manufacters have calibrated the GMagic constant for each
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 band on a per-unit basis, and the unit-to-unit difference is on the order of
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 1-2 half-dB units, i.e., rarely more than 1 dB. The difference from one board
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 design to another tends to be a little greater, on the order of 10 half-dB
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 units, and is probably due to the difference in insertion losses at various
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 points in the Rx signal path. (Ideally these insertion losses should be zero,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 but the world is not ideal.)
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 GMagic calibration is done by connecting a signal generator putting out a
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 precisely controlled signal to the DUT's antenna connector or RF test port,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29 making a power measurement with the Calypso DSP and computing GMagic per the
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 simple equation above.
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 Our FreeCalypso version of the GMagic calibration procedure is closely based on
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 the Sara version, described on pages 28-32 of the Sara document
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 rf_calibration.pdf (see TI-docs). The LoCosto calibration document does not
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 include a GMagic calibration procedure, but LoCosto is a very different beast,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 with both the baseband processor and the RF transceiver in the same chip, and
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 using that mysterious DRP - perhaps LoCosto doesn't need GMagic calibration,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 perhaps it is absorbed into DRP calibration instead.
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 Per the available Sara RF calibration document, we set the signal generator's
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41 output level to -74.5 dBm, and set the AGC in the Rita RF chip to 34 dB for the
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 GMagic calibration step. However, we use the ARFCNs from the LoCosto document:
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 37 for the EGSM band, 698 for DCS, 661 for PCS and 189 for GSM850. The old Sara
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 document covers only 900 and 1800 MHz bands (I'm guessing Sara probably did not
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 support 1900 MHz, let alone 850), the LoCosto document is quadband throughout,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 and the LoCosto ARFCNs are closer to the true centre of each band.
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 RSSI channel compensation
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49 =========================
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51 The GMagic constant is calibrated at the centre frequency for each downlink
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52 band, but the true value of this "magic gain" varies slightly with the frequency
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 channel. The drawing on page 34 of the Sara document suggests that this
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 frequency channel-dependent variation is caused by frequency-dependent variation
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55 in the insertion loss of the Rx SAW filters. This frequency channel-dependent
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 variation in the "magic gain" is customarily calibrated on a per-unit basis
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 (even on LoCosto, apparently), and the available documents suggest that this
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58 calibration is done in order to make RSSI reporting more accurate.
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60 Once again our FreeCalypso version of this RSSI channel calibration procedure
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 is based on the Sara document, rather than LoCosto, except for the ARFCNs. The
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62 LoCosto document gives ARFCN ranges for Rx channel calibration for all 4 bands,
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 and these ranges fully agree with what Openmoko's factory programmed in their
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64 /gsm/rf/rx/calchan.* files, thus we have adopted the ARFCN ranges and test
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65 ARFCNs from LoCosto for all 4 bands.
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
67 Note that the LoCosto document indicates the use of a different signal generator
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
68 level (-68.5 dBm instead of -74.5), and tells the operator to set the AGC gain
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69 to 0 dB. The latter must be a LoCosto-ism, as it is definitely not correct for
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
70 our Calypso+Iota+Rita chipset. If we set the signal generator level to
65
e7b9a9903f14 doc/Rx-cal-theory: typo fix
Mychaela Falconia <falcon@freecalypso.org>
parents: 63
diff changeset
71 -68.5 dBm, we would need to set the Rita AGC to 28 dB, but the Mother of
63
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
72 FreeCalypso decided to go with the safer choice of using the Sara settings of
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
73 -74.5 dBm generator level, 34 dB AGC.
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
74
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
75 FreeCalypso Rx calibration tools
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
76 ================================
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
77
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
78 The present suite of RF calibration tools includes two programs for Rx path
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
79 calibration:
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
80
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
81 fc-rfcal-gmagic
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
82
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
83 This program is a study-only tool. It measures the GMagic constant for
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
84 the user-specified band (either at that band's default ARFCN or at a
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
85 user-specified ARFCN) and prints it out, but does not write anything
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
86 into the Calypso device's FFS.
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
87
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
88 fc-rfcal-rxband
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
89
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
90 This program is intended for production use. It performs both the
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
91 GMagic and the RSSI channel compensation calibration steps, uploads the
131abadbd74d doc/Rx-cal-theory written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
92 results to the DUT and saves them in FFS.