private TVCLib.Tvc CreateAFG3022() { //刷新设备列表 TekVRAPI.CRemoteAPI remoteAPI = new TekVRAPI.CRemoteAPI(); if (!remoteAPI.TekVIsRMUPdateActive()) { remoteAPI.TekVStartRmUpdate(""); } //寻找AFG3022设备 string descriptor = null; TekVISANet.VISA visa = new TekVISANet.VISA(); ArrayList deviceList = new ArrayList(); if (visa.FindResources("USB?*INSTR", out deviceList)) { descriptor = deviceList[0].ToString(); } afg3022.Descriptor = descriptor; if (descriptor != null) { Log.MessAgeLog(".\\xhtst.log", "找到USB设备" + descriptor); } else { Log.MessAgeLog(".\\xhtst.log", "未找到设备"); } // CreateFM(1, 1700, 0.100, 10.3, 11); visa.Dispose(); visa = null; return(afg3022); }
public static ArrayList GetDevDescList() { deviceList = null; TekVRAPI.CRemoteAPI remoteAPI = new TekVRAPI.CRemoteAPI(); if (!remoteAPI.TekVIsRMUPdateActive()) { remoteAPI.TekVStartRmUpdate(""); } //寻找AFG3022设备 string descriptor = null; TekVISANet.VISA visa = new TekVISANet.VISA(); if (visa.FindResources("USB?*INSTR", out deviceList)) { descriptor = deviceList[0].ToString(); } visa.Dispose(); visa = null; return deviceList; }
static public ArrayList GetDevDescList() { deviceList = null; TekVRAPI.CRemoteAPI remoteAPI = new TekVRAPI.CRemoteAPI(); if (!remoteAPI.TekVIsRMUPdateActive()) { remoteAPI.TekVStartRmUpdate(""); } //寻找AFG3022设备 string descriptor = null; TekVISANet.VISA visa = new TekVISANet.VISA(); if (visa.FindResources("USB?*INSTR", out deviceList)) { descriptor = deviceList[0].ToString(); } visa.Dispose(); visa = null; return(deviceList); }
private TVCLib.Tvc CreateAFG3022() { //刷新设备列表 TekVRAPI.CRemoteAPI remoteAPI = new TekVRAPI.CRemoteAPI(); if (!remoteAPI.TekVIsRMUPdateActive()) { remoteAPI.TekVStartRmUpdate(""); } //寻找AFG3022设备 string descriptor = null; TekVISANet.VISA visa = new TekVISANet.VISA(); ArrayList deviceList = new ArrayList(); if (visa.FindResources("USB?*INSTR", out deviceList)) { descriptor = deviceList[0].ToString(); } afg3022.Descriptor = descriptor; if (descriptor != null) { Log.MessAgeLog(".\\xhtst.log", "找到USB设备" + descriptor); } else { Log.MessAgeLog(".\\xhtst.log", "未找到设备"); } // CreateFM(1, 1700, 0.100, 10.3, 11); visa.Dispose(); visa = null; return afg3022; }