NI RFmx SpecAn Marker Functions - ni/grpc-device GitHub Wiki

Marker Functions

RFmxSpecAn_MarkerCfgNumberOfMarkers

int32 __stdcall RFmxSpecAn_MarkerCfgNumberOfMarkers (niRFmxInstrHandle instrumentHandle, char selectorString[], int32 numberOfMarkers);

Purpose

Configures the number of markers.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name. If you do not specify the signal name, the default signal instance is used.

Example:

""

"signal::sig1"

You can use the RFmxSpecAn_BuildSignalString) function to build the selector string).
numberOfMarkers int32 Specifies the number of markers.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerCfgType

int32 __stdcall RFmxSpecAn_MarkerCfgType (niRFmxInstrHandle instrumentHandle, char selectorString[], int32 markerType);

Purpose

Configures the marker type.

Use "marker<n>" as the selector string to configure this function.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name and marker number. If you do not specify the signal name, the default signal instance is used.

Example:

"marker0"

"signal::sig1/marker0"

You can use the RFmxSpecAn_BuildMarkerString2 )function to build the selector string).
markerType int32 Specifies whether the marker is disabled (Off) or is enabled (On) either as a normal marker or a delta marker.
RFMXSPECAN_VAL_MARKER_MARKER_TYPE_OFF (0) The marker is disabled.
RFMXSPECAN_VAL_MARKER_MARKER_TYPE_NORMAL (1) The marker is enabled as a normal marker.
RFMXSPECAN_VAL_MARKER_MARKER_TYPE_DELTA (3) The marker is enabled as a delta marker.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerCfgReferenceMarker

int32 __stdcall RFmxSpecAn_MarkerCfgReferenceMarker (niRFmxInstrHandle instrumentHandle, char selectorString[], int32 referenceMarker);

Purpose

Configures the reference marker to a delta marker.

Use "marker<n>" as the selector string to configure this function.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name and marker number. If you do not specify the signal name, the default signal instance is used.

Example:

"marker0"

"signal::sig1/marker0"

You can use the RFmxSpecAn_BuildMarkerString2 )function to build the selector string).
referenceMarker int32 Specifies the marker to be used as reference marker when you set the RFMXSPECAN_ATTR_MARKER_TYPE attribute to RFMXSPECAN_VAL_MARKER_MARKER_TYPE_DELTA. This parameter is not used when you set the RFMXSPECAN_ATTR_MARKER_TYPE attribute to RFMXSPECAN_VAL_MARKER_MARKER_TYPE_NORMAL.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerCfgXLocation

int32 __stdcall RFmxSpecAn_MarkerCfgXLocation (niRFmxInstrHandle instrumentHandle, char selectorString[], float64 markerXLocation);

Purpose

Configures the X location of the marker. Ensure that you configure the reference marker X location or perform peak search on the reference marker before configuring the X location for the Delta marker.

Use "marker<n>" as the selector string to configure this function.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name and marker number. If you do not specify the signal name, the default signal instance is used.

Example:

"marker0"

"signal::sig1/marker0"

You can use the RFmxSpecAn_BuildMarkerString2 )function to build the selector string).
markerXLocation float64 Specifies the X location of the marker on the trace when you set the marker type to Normal. The X location is relative to the value of the reference marker when you set the marker type to Delta.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerCfgThreshold

int32 __stdcall RFmxSpecAn_MarkerCfgThreshold (niRFmxInstrHandle instrumentHandle, char selectorString[], int32 thresholdEnabled, float64 threshold);

Purpose

Configures the threshold to use for peak search.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name. If you do not specify the signal name, the default signal instance is used.

Example:

""

"signal::sig1"

You can use the RFmxSpecAn_BuildSignalString) function to build the selector string).
thresholdEnabled int32 Specifies whether to enable the threshold for the trace while finding the peaks.
RFMXSPECAN_VAL_MARKER_THRESHOLD_ENABLED_FALSE (0) Disables the threshold for the trace while finding the peaks.
RFMXSPECAN_VAL_MARKER_THRESHOLD_ENABLED_TRUE (1) Enables the threshold for the trace while finding the peaks.
threshold float64 Specifies the threshold for finding the peaks on the trace.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerCfgTrace

int32 __stdcall RFmxSpecAn_MarkerCfgTrace (niRFmxInstrHandle instrumentHandle, char selectorString[], int32 trace);

Purpose

Configures the measurement trace to be used by the marker.

Use "marker<n>" as the selector string to configure this function.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name and marker number. If you do not specify the signal name, the default signal instance is used.

Example:

"marker0"

"signal::sig1/marker0"

You can use the RFmxSpecAn_BuildMarkerString2 )function to build the selector string).
trace int32 Specifies the trace.
RFMXSPECAN_VAL_MARKER_TRACE_ACP_SPECTRUM (0) The marker uses the ACP spectrum trace.
RFMXSPECAN_VAL_MARKER_TRACE_CCDF_GAUSSIAN_PROBABILITIES_TRACE (1) The marker uses the CCDF Gaussian probabilities trace.
RFMXSPECAN_VAL_MARKER_TRACE_CCDF_PROBABILITIES_TRACE (2) The marker uses the CCDF probabilities trace.
RFMXSPECAN_VAL_MARKER_TRACE_CHP_SPECTRUM (3) The marker uses the CHP spectrum trace.
RFMXSPECAN_VAL_MARKER_TRACE_FCNT_POWER_TRACE (4) The marker uses the FCnt power trace.
RFMXSPECAN_VAL_MARKER_TRACE_OBW_SPECTRUM (5) The marker uses the OBW spectrum trace.
RFMXSPECAN_VAL_MARKER_TRACE_SEM_SPECTRUM (6) The marker uses the SEM spectrum trace.
RFMXSPECAN_VAL_MARKER_TRACE_SPECTRUM (7) The marker uses the Spectrum trace.
RFMXSPECAN_VAL_MARKER_TRACE_TXP_POWER_TRACE (8) The marker uses the TXP power trace.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerCfgPeakExcursion

int32 __stdcall RFmxSpecAn_MarkerCfgPeakExcursion (niRFmxInstrHandle instrumentHandle, char selectorString[], int32 peakExcursionEnabled, float64 peakExcursion);

Purpose

Configures the peak excursion.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name. If you do not specify the signal name, the default signal instance is used.

Example:

""

"signal::sig1"

You can use the RFmxSpecAn_BuildSignalString) function to build the selector string).
peakExcursionEnabled int32 Specifies whether to enable the peak excursion check for the trace while finding the peaks.
RFMXSPECAN_VAL_MARKER_PEAK_EXCURSION_ENABLED_FALSE (0) Disables the peak excursion check for the trace while finding the peaks.
RFMXSPECAN_VAL_MARKER_PEAK_EXCURSION_ENABLED_TRUE (1) Enables the peak excursion check for the trace while finding the peaks.
peakExcursion float64 Specifies the peak excursion value for finding the peaks on trace when you set the peakExcursionEnabled parameter to RFMXSPECAN_VAL_MARKER_PEAK_EXCURSION_ENABLED_TRUE. The signal should rise and fall by at least the peak excursion value, above the threshold, to be considered as a peak.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerPeakSearch

int32 __stdcall RFmxSpecAn_MarkerPeakSearch (niRFmxInstrHandle instrumentHandle, char selectorString[], int32 *numberOfPeaks);

Purpose

Moves the marker to the highest peak above the threshold on the configured trace.

Use "marker<n>" as the selector string to read results from this function.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name, result name, and marker number. If you do not specify the signal name, the default signal instance is used.

Example:

"marker0"

"signal::sig1/marker0"

"result::r1/marker0"

"signal::sig1/result::r1/marker0"

You can use the RFmxSpecAn_BuildMarkerString2 )function to build the selector string).
Output
Name Type Description
numberOfPeaks int32* Returns the total number of peaks above the threshold, when you enable the marker threshold.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerNextPeak

int32 __stdcall RFmxSpecAn_MarkerNextPeak (niRFmxInstrHandle instrumentHandle, char selectorString[], int32 nextPeak, int32 *nextPeakFound);

Purpose

Moves the marker to the next highest or next left or next right peak above the threshold on the configured trace.

Use "marker<n>" as the selector string to read results from this function.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name, result name, and marker number. If you do not specify the signal name, the default signal instance is used.

Example:

"marker0"

"signal::sig1/marker0"

"result::r1/marker0"

"signal::sig1/result::r1/marker0"

You can use the RFmxSpecAn_BuildMarkerString2 )function to build the selector string).
nextPeak int32 Specifies the next peak on the trace.
RFMXSPECAN_VAL_MARKER_NEXT_PEAK_NEXT_HIGHEST (0) Moves the marker to the next highest peak above the threshold on the configured trace.
RFMXSPECAN_VAL_MARKER_NEXT_PEAK_NEXT_LEFT (1) Moves the marker to the next peak to the left of the configured trace.
RFMXSPECAN_VAL_MARKER_NEXT_PEAK_NEXT_RIGHT (2) Moves the marker to the next peak to the right of the configured trace.
Output
Name Type Description
nextPeakFound int32* Indicates whether the function has found the next peak on the trace.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors

RFmxSpecAn_MarkerFetchXY

int32 __stdcall RFmxSpecAn_MarkerFetchXY (niRFmxInstrHandle instrumentHandle, char selectorString[], float64* markerXLocation, float64* markerYLocation);

Purpose

Returns the X and Y locations of the marker.

Parameters

Input
Name Type Description
instrumentHandle niRFmxInstrHandle Identifies the RFmx session. You can obtain this parameter from the RFmxSpecAn_Initialize) function.
selectorString char[] Comprises the signal name, result name, and marker number. If you do not specify the signal name, the default signal instance is used.

Example:

"marker0"

"signal::sig1/marker0"

"result::r1/marker0"

"signal::sig1/result::r1/marker0"

You can use the RFmxSpecAn_BuildMarkerString2 )function to build the selector string).
Output
Name Type Description
markerXLocation float64* Returns the marker X location.
markerYLocation float64* Returns the marker Y location.

Return Value

Name Type Description
status int32 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 RFmx function to determine if an error has occurred.

To obtain a text description of the status code and additional information about the error condition, call the RFmxSpecAn_GetError) function.

The general meaning of the status code is as follows:
Value Meaning
0 Success
Positive Values Warnings
Negative Values Errors
⚠️ **GitHub.com Fallback** ⚠️