AFC measurement and set

Supported in modem firmware v1.2.0 and later.

The command measures or sets the AFC correction value for a given frequency. The default correction value is 0.

Some frequency error may occur because the signal generator’s and nRF9160’s reference clocks are different. This test allows to measure or set frequency error and use the result value as compensation in subsequent tests. This improves the correctness of Signal-to-Noise Ratio (SNR) tests and transmission frequency, but has no significant effect on the power measurement results in RX ON or TX ON tests. The response value is stored in device memory and can be used in RX and Global Positioning System (GPS) SNR tests if the AFC correction enabling parameter, for example <param4> in the RX SNR test, is 1.

The measurement expects the Carrier Wave (CW) in the signal generator to be 120 kHz lower than the given frequency. For example, if DUT frequency is 830 MHz, the signal generator must be set to 829.880 MHz.

Note: The same result value is used automatically in TX ON and RX ON tests.

The command parameters and their defined values are the following:

<test>
4 – AFC

AFC measurement

<operation>
1 – ON (measure)
Note: "OFF" is not needed due to automatic stop. Mode is always M1. The stored value is reset when the device is booted.

AFC measurement has three parameters:

<param0>
3GPP band number.
<param1>
Frequency (100 kHz)
<param2>
RX signal power at antenna in dBm

Response syntax when <operation> is ON:

%XRFTEST: <AFC_correction_value>

The response value is the following:

<AFC_correction_value> - Measured AFC correction value in Hz.

The following command example measures the AFC correction value for band 1, 2140.0 MHz, -40 dBm:

%XRFTEST=4,1,1,21400,-40
%XRFTEST: 349
OK

AFC set

The command allows to manually set the AFC correction value in Hz, which can be used in RX and GPS SNR tests if the AFC correction enabling parameter, for example <param4> in the RX SNR test, is 1. The value set with this command overwrites the value obtained with AFC measurement.

This value is used automatically in the RX ON and TX ON tests. To not use the AFC correction value, for example in TX ON or RX ON tests, set it to 0.

The command parameter and its value is the following:

<operation>
3 – SET

AFC SET has one parameter:

<param0>
AFC correction value [Hz]

Response syntax when <operation> is SET:

%XRFTEST: OK

The following command example sets AFC correction value to 349 Hz:

%XRFTEST=4,3,349
OK