/// <summary> /// Load an existing GPIB port configuration from disk. /// </summary> /// <param name="name">name of device attached to GPIB port</param> /// <param name="config">GPIB port configuration</param> public static void Load(string name, out IGpibConfig config) { config = null; using (FileStream stream = ReadStream(name)) { config = (IGpibConfig)PortFactory.Create(PortType.Gpib, stream); } }
public void SaveGpibTest() { IGpibConfig config = null; //ConfigManager.Create("SigGen", out config); ConfigManager.Load("SigGen", out config); ConfigManager.Save("SigGen", config); }
public UIConfigProperties(string name, IGlobalConfig globalConfig, ISerialConfig serialConfig1, ISerialConfig serialConfig2, ISerialConfig serialConfig3, ISerialConfig serialConfig4, IGpibConfig sigGenConfig1, IGpibConfig sigGenConfig2, IGpibConfig powerConfig1, IGpibConfig powerConfig2, IGpibConfig powerConfig3, IGpibConfig powerConfig4, IGpibConfig powerMeter, ITelnetConfig telentConfig) { Name = name; SerialConfig1 = serialConfig1; SerialConfig2 = serialConfig2; SerialConfig3 = serialConfig3; SerialConfig4 = serialConfig4; GlobalConfig = globalConfig; SigGenConfig1 = sigGenConfig1; SigGenConfig2 = sigGenConfig2; PowerConfig1 = powerConfig1; PowerConfig2 = powerConfig2; PowerConfig3 = powerConfig3; PowerConfig4 = powerConfig4; PowerMeter = powerMeter; TelnetConfig = telentConfig; }
/// <summary> /// Save the GPIB port configuration for the given device. /// </summary> /// <param name="name">name of device attached to GPIB port</param> /// <param name="config">GPIB port configuration</param> public static void Save(string name, IGpibConfig config) { Save(name, (object)config); }
/// <summary> /// Create a new GPIB port configuration for a given device filled with default values. /// </summary> /// <param name="name">name of device attached to GPIB port</param> /// <param name="config">GPIB port configuration</param> public static void Create(string name, out IGpibConfig config) { config = (IGpibConfig)PortFactory.Create(PortType.Gpib, name); }
public void LoadGpibTest() { IGpibConfig config = null; ConfigManager.Load("SigGen", out config); }
public void CreateGpibTest() { IGpibConfig config = null; ConfigManager.Create("SigGen", out config); }