ni5690_configureGain

NI RF Signal Conditioning Devices Help (NI-5690 14.5)

Edition Date: March 2015

Part Number: 371326D-01

»View Product Info
Download Help (Windows Only)

ViStatus Status = ni5690_configureGain (ViSession Instrument_Handle, ViConstString Channel_Name, ViReal64 Gain, ViReal64 Frequency);

Purpose

Configures the gain (in dB) of a channel. A negative value indicates attenuation. This function returns an error if the requested gain is too high or too low for the device to configure at the specified frequency. This function also returns an error if the appropriate channel name is not specified.

Note  The NI 5690 and NI 5691 support configurable gain for CH 1 only, while the NI 5695 supports configurable gain for CH 0 only.

Parameters

Input
Name Type Description
Instrument_Handle ViSession Identifies the instrument session. The instrument handle was obtained from the ni5690_init function and identifies a particular instrument session.
Channel_Name ViConstString Specifies the channel through which the input RF signal is routed and in which Gain is applied.
Gain ViReal64 Specifies the gain applied to the input RF signal in dB. Actual gain may be set to the closest higher available gain setting. The gain may be set to a negative number to indicate attenuation.
Frequency ViReal64 Specifies the frequency of the input RF signal in Hz.

Return Value

Name Type Description
Status ViStatus Returns the status code of this operation. The status code either indicates success or describes an error or warning condition. Examine the status code from each call to an instrument driver function to determine if an error occurred.

To obtain a text description of the status code, call the ni5690_error_message function.

The general meaning of the status code is as follows:

Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

WAS THIS ARTICLE HELPFUL?

Not Helpful