NI-RFPM API Reference

Table of Contents

NIRfpm Class

  • Updated2023-12-28
  • 5 minute(s) read
NIRfpm Class

NIRfpm Class

Represents an NI-RFPM instrument driver session.

Inheritance Hierarchy

SystemObject
  NationalInstruments.ModularInstruments.NIRfpmNIRfpm

Namespace:  NationalInstruments.ModularInstruments.NIRfpm
Assembly:  NationalInstruments.ModularInstruments.NIRfpm.Fx40 (in NationalInstruments.ModularInstruments.NIRfpm.Fx40.dll) Version: 2023

Syntax

public sealed class NIRfpm : IIviDriver, 
	IServiceProvider, IDisposable
Public NotInheritable Class NIRfpm
	Implements IIviDriver, IServiceProvider, IDisposable

The NIRfpm type exposes the following members.

Constructors

  NameDescription
Public methodNIRfpm(IntPtr)
Initializes a new instance of the NIRfpm class.
Public methodNIRfpm(String, NIRfsa, NIRfsg, NIRfpmSwitch)
Initializes a new instance of the NIRfpm class.
This method does not support the mmWave subsystem.
Public methodNIRfpm(String, NIRfsa, NIRfsg, String)
Initializes a new instance of the NIRfpm class.
Supported devices: mmWave subsystem
Public methodNIRfpm(String, IntPtr, IntPtr, IntPtr)
Initializes a new instance of the NIRfpm class.
This method does not support the mmWave subsystem.
Public methodNIRfpm(String, NIRfsa, NIRfsg, NIRfpmSwitch, String)
Initializes a new instance of the NIRfpm class.
This method does not support the mmWave subsystem.
Public methodNIRfpm(String, IntPtr, IntPtr, IntPtr, String)
Initializes a new instance of the NIRfpm class.
This method does not support the mmWave subsystem.
Top

Properties

  NameDescription
Public propertyCalibration
Gets an RfpmCalibration object that defines methods and properties that perform calibration on NI-RFPM instruments.
This property does not support the mmWave subsystem.
Public propertyDriverOperation
Gets an RfpmDriverOperation object that defines methods and properties for common operations on the NI-RFPM driver.
Public propertyDriverState
Gets a string that represents the current state of the driver.
Public propertyIdentity
Gets an RfpmDriverIdentity object which defines the methods and properties for identifying the NI-RFPM driver.
Public propertyIsDisposed
Gets a value indicating whether the session has been disposed.
Public propertyMeasurements
Gets an RfpmMeasurements object that defines methods and properties that perform measurements on NI-RFPM instruments.
Public propertyRfmxCallbacks
Gets an RfpmRfmxCallbacks object that provides functionality for RFmx to call into RFPM.
This property does not support the mmWave subsystem.
Public propertyRfpmSwitchSession
Gets an NIRfpmSwitch session object representing the underlying NI-RFPM Switch session used by NI-RFPM.
This property does not support the mmWave subsystem.
Public propertyRfsaSession
Gets an NIRfsa session object representing the underlying NI-RFSA session used by NI-RFPM.
Public propertyRfsgSession
Gets an NIRfsg session object representing the underlying NI-RFSG session used by NI-RFPM.
Public propertySweepSettingsManager
Gets the RfpmSweepSettingsManager object used for loading and reading sweep settings.
Public propertyUtility
Gets an RfpmDriverUtility object to access the utility features on the NI-RFPM driver.
Public propertyUtilityForSwitch
Gets an RfpmUtilityForSwitch object that provides functionality to connect or disconnect channels on NIRfpmSwitch.
This property does not support the mmWave subsystem.
Top

Methods

  NameDescription
Public methodClose
Closes the session to the device.
Public methodDispose
Closes the NIRfpm session and deallocates the reserved resources, if not already disposed.
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetInstrumentHandle
Returns the SafeHandle representing the value of the underlying NIRfpm instrument handle.
Public methodGetService
Returns a service object of the type mentioned in the serviceType parameter.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top

Remarks

Use this class to configure and control your NI-RFPM instrument. A NIRfpm session works in conjunction with three other sessions:

  1. A valid NI-RFSA session;
  2. A valid NI-RFSG session; and
  3. A valid NI-RFPM Switch session.

NI-RFPM implements vector network analyzer (VNA) functionality using the vector signal transceiver (VST), including the hardware and software required to measure S-parameters on multiple ports.

Examples

' Create a session.
Dim session As NIRfpm = New NIRfpm(resourceName, niRfsa, niRfsg, niRfpmSwitch)

' Load sweep settings.
session.SweepSettingsManager.LoadFromFile(sweepSettingsFilePath)

' Calibration is optional.
session.UserCalibration.Configure(String.Empty, True, True, True)
session.UserCalibration.Initialize()
session.UserCalibration.PerformAction(portNames, sweepSettingName)
session.UserCalibration.WaitUntilDone(TimeSpan.MaxValue)
session.UserCalibration.Close(CloseUserCalibrationAction.Commit)

' Perform measurements.
session.Measurements.Initiate(portNames, sweepSettingName)
session.Measurements.WaitUntilDone(TimeSpan.MaxValue)

Dim fetchResults As RfpmMultipleMeasurementResult(Of Double) = Nothing
session.Measurements.FetchAllSParameters(DoubleMeasurementFormat.LinearMagnitude, TimeSpan.MaxValue, fetchResults)

' [Consume the fetched data here]

Examples

// Create a session.
NIRfpm session = new NIRfpm(resourceName, niRfsa, niRfsg, niRfpmSwitch);

// Load sweep settings.
session.SweepSettingsManager.LoadFromFile(sweepSettingsFilePath);

// Calibration is optional.
session.UserCalibration.Configure(string.Empty, true, true, true);
session.UserCalibration.Initialize();
session.UserCalibration.PerformAction(portNames, sweepSettingName);
session.UserCalibration.WaitUntilDone(TimeSpan.MaxValue);
session.UserCalibration.Close(CloseUserCalibrationAction.Commit);

// Perform measurements.
session.Measurements.Initiate(portNames, sweepSettingName);
session.Measurements.WaitUntilDone(TimeSpan.MaxValue);

RfpmMultipleMeasurementResult<double> fetchResults = null;
session.Measurements.FetchAllSParameters(DoubleMeasurementFormat.LinearMagnitude, TimeSpan.MaxValue, ref fetchResults);

// [Consume the fetched data here]

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Log in to get a better experience