Attenuation

NI Tuner

Attenuation

This section describes how attenuation is handled by the NI–TUNER driver. The user modifies attenuation through the niTuner Set Attenuation VI or the niTuner_setAttenuation function.

The Hardware

The downconverter signal chain has five programmable attenuators: three RF attenuators at the beginning of the chain and two IF attenuators near the end of the chain. They are set up in the following sequence:

Attenuator Sequence
Attenuator Asserted Value
RF Attenuator 1 20 dB
RF Attenuator 2 20 dB
RF Attenuator 3 10 dB
IF Attenuator 1 20 dB
IF Attenuator 2 10 dB

Attenuators are either set/asserted or not set/asserted. This allows a dynamic range of RF attenuation from 0-50 dB and a dynamic range of IF attenuation from 0-30 dB. Overall attenuation within the signal chain is the sum of all the attenuators set, for a range of 0-80 dB.

Coercion, Step 1

The five attenuators are configured based upon the mixer and reference levels set in the

niTuner Set Attenuation VI or the niTuner_setAttenuation function.

First NI–TUNER checks whether the user intends to use the AutoMode feature. In AutoMode, the user defines the reference level, while NI–TUNER determines the appropriate mixer level. AutoMode is activated in NI–TUNER by setting a mixer level value above 1000. This feature will then attempt to set the mixer level to -20 dBm and adjust within the algorithmic coercions described below. In AutoMode the only warning the user may see concerns coercion to correct an invalid reference level.

NI–TUNER coerces the settings according to the following rules:

  • The mixer level may not be above 0 dBm. If the mixer level breaks this rule, NI–TUNER sets the mixer level to 0 dBm and returns this warning: "Mixer level cannot exceed 0 dBm. The mixer level setting is coerced to 0 dBm"
  • The reference level may not be above 50 dBm. If the reference level is greater than 50 dBm, NI–TUNER sets the reference level to 50 dBm and returns this warning: "The reference level cannot exceed 50 dBm. The reference level setting is coerced to 50 dBm"
  • The mixer level may not be greater than the reference level. If the mixer level is greater than the reference level, NI–TUNER sets the mixer level equal to the current value of the reference level and returns this warning: "The specified mixer level does not fall between the reference level and the reference level minus 50 dBm. The mixer level setting is coerced to the nearest of these two bounds"
  • The mixer level may not be less than the reference level minus 50 dBm. If the mixer level breaks this rule, NI–TUNER sets the mixer level to the value of reference level minus 50 dBm and returns this warning: "The specified mixer level does not fall between the reference level and the reference level minus 50 dBm. The mixer level setting is coerced to the nearest of these two bounds"

After this, coercion occurs only if the requested reference level and mixer level create an impossible state in programming the downconverter's attenuators.

Setting the Attenuators, Step 2

Understanding the parts played by the reference level and the mixer level is key to setting the individual attenuators. NI–TUNER sets the RF attenuators first.

Let D be the difference between the reference level and the mixer level, such that

D = reference level - mixer level

This formula correlates directly with the range of possible RF attenuator settings. Recall that the RF attenuators have a range of 0-50 dB. The coercions described in the previous section ensure that the mixer level will be less than the reference level and that the mixer level will not be more than 50 dBm less than the reference level. D is then directly proportional to the total RF attenuation, a value between 0-50 dB. All that remains is to set the RF attenuators as follows (refer to the Attenuator Sequence table above):

RF Attenuator Settings
D Attenuators
0 None are set
10 RF Attenuator 3
20 RF Attenuator 1
30 RF Attenuators 1 and 3
40 RF Attenuators 1 and 2
50 RF Attenuators 1, 2, and 3

Attenuation of the signal on the other end of the chain is modified by configuring the IF attenuators.

Think of the IF attenuators as adjustable compensation for the inherent 30 dB gain of the downconverter. Let I be the 30 dB adjustment of our ratio, such that

I = 30 dB + Reference Level - D

or simply,

I = 30 dB + Mixer Level

Here the NI–TUNER driver may be forced to perform another coercion. The value of the mixer level is less than or equal to 0 dBm due to previous coercion, but what happens if the mixer level is less than 30 dBm? This would produce a negative attenuation (i.e., a gain), and there are no programmable IF gains available. If I is less than 0 dB, then NI–TUNER coerces I to 0 dB and returns this warning: "A mixer level less than -30 dBm produces an IF output below the nominal level of 0 dBm. See your NI–TUNER Reference Help".

I is directly proportional to the total IF attenuation, a value between 0 - 30 dB. The IF attenuators are set as follows (refer to the Attenuator Sequence table above):

IF Attenuator Settings
I Attenuators
0 None are set
10 IF Attenuator 2
20 IF Attenuator 1
30 IF Attenuators 1 and 2

One More Adjustment

After the attenuation is set, if the user makes driver calls to the niTuner Set Freq VI or the niTuner_setFreq function, an additional adjustment may be made. If at least one frequency requested of the NI–TUNER is less than 15 MHz, the downconverter functions instead as an upconverter. This process produces a saturation in the signal. In order to account for this saturation, NI–TUNER immediately sets the 10 dB IF attenuator if it is not already set.