Getting Values for Specifications (TSM)
- Updated2025-07-31
- 1 minute(s) read
Specification files (.specs) define a set of variables and associated numeric values that you reference in code modules to configure hardware or provide input to tests procedures. Use the Get Specification(s) Value(s) VI or the GetSpecificationsValue or GetSpecificationsValues .NET methods to query one variable or an array of variables and return the calculated value or values. The VI and methods return an error or exception when you reference a variable that does not exist in the specifications file, which can result in a run-time error when the sequence executes.
| LabVIEW |
|
| .NET (C#) |
public static void ExampleCodeModule(ISemiconductorModuleContext semiconductorModuleContext, string[] pins)
{
NIDCPower[] dcPowerSessions;
string[] channelStrings;
var pinQuery = semiconductorModuleContext.GetNIDCPowerSessions(pins, out dcPowerSessions, out channelStrings);
double vccMax = semiconductorModuleContext.GetSpecificationsValue("DC.vcc_max");
SetupMeasurement(dcPowerSessions, channelStrings, vccMax);
var results = PerformMeasurement(dcPowerSessions, channelStrings);
pinQuery.Publish(results);
}
|