我正在尝试使用功率计执行源功率校准,方法是从运行
matlab的远程PC发出DCOM命令。
如果我使用PNA的前面板,源功率校准工作正常。
功率计:地址为13的gpib上的N1912A,通道A上的E4413A传感器:PNA:N5242A,端口1,测量让app = pna 835x应用程序对象我的代码* app.Preset; * *%设置频率和点数* *
app.Ac
tiveChannel.StartFrequency = 60e6; * * app.ActiveChannel.StopFrequency = 2.51e9; * * app.ActiveChannel.NumberOfPoints = 101; * *%将参数更改为非比例R1 * * app.ActiveMeasurement.ChangeParameter('R1',1
); * *%config功率计测量* * app.SourcePowerCalibrator.PowerMeterGPIBAddress = 13; * * app.UsePowerSensorFrequencyLimits = 0; * * app.SourcePowerCalibrator.IterationsTolerance = 0.05; * * app.SourcePowerCalibrator.MaximumIterationsPerPoint = 5; * * app
.SourcePowerCalibrator.ReadingsTolerance = 0.05; * * app.SourcePowerCalibrator.ReadingsPerPoint = 3; * * app.SourcePowerCalibrator.SetCalInfoEx(1,1,0.0,'True'); * * pschan = app.SourcePowerCalibrator.PowerSensors.Item(1)
.PowerMeterChannel; * * app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter',pschan,'True'); *最后一行
导致以下错误:+ ???
调用错误,调度异常:+ +描述:方法AcquirePowerReadingsEx失败:找不到通道。+我已经尝试了以下所有版本的AcquirePowerReadingsEx命令。
它们都返回上面列出的相同错误。
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'ASEN',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','ASEN','True');
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'naPowerSensor_A',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','naPowerSensor_A','True');
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'E4413A',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','E4413A','True');
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'E4413A',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','E4413A','True');
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'1',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','1','True');
注意,以下三个命令工作正常:* app.SourcePowerCalibrator.CheckPower(0,80e6)* app.SourcePowerCalibrator.CheckPower('naPowerSensor_A',80e6)* app.SourcePowerCalibrator.CheckPower(pschan,80e6)%pschan定义如上
帮助将不胜感激。编辑:golfnut于2012年8月15日下午3:08
以上来自于谷歌翻译
以下为原文
I'm trying to perform a source power calibration with a power meter by issuing the DCOM commands from a remote PC running Matlab. The source power calibration works fine if I use the front panel of the PNA.
Power Meter: N1912A on gpib with address 13, with E4413A sensor on channel A
PNA: N5242A, port 1, measurement
let app = the pna 835x application object
my code
*app.Preset;*
*%set frequencies and number of points*
*app.ActiveChannel.StartFrequency=60e6;*
*app.ActiveChannel.StopFrequency=2.51e9;*
*app.ActiveChannel.NumberOfPoints=101;*
*%change parameter to unratioed R1*
*app.ActiveMeasurement.ChangeParameter('R1',1);*
*%config power meter measurements*
*app.SourcePowerCalibrator.PowerMeterGPIBAddress=13;*
*app.UsePowerSensorFrequencyLimits = 0;*
*app.SourcePowerCalibrator.IterationsTolerance = 0.05;*
*app.SourcePowerCalibrator.MaximumIterationsPerPoint = 5;*
*app.SourcePowerCalibrator.ReadingsTolerance = 0.05;*
*app.SourcePowerCalibrator.ReadingsPerPoint = 3;*
*app.SourcePowerCalibrator.SetCalInfoEx(1,1,0.0,'True');*
*pschan=app.SourcePowerCalibrator.PowerSensors.Item(1).PowerMeterChannel;*
*app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter',pschan,'True');*
The last line causes the following error:
+??? Invoke Error, Dispatch Exception:+
+Description: Method AcquirePowerReadingsEx failed: Channel not found.+
I've tried all of the following versions of the AcquirePowerReadingsEx command. They all return the same error listed above.
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'ASEN',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','ASEN','True');
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'naPowerSensor_A',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','naPowerSensor_A','True');
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'E4413A',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','E4413A','True');
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'E4413A',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','E4413A','True');
* app.SourcePowerCalibrator.AcquirePowerReadingsEx(0,'1',1);
* app.SourcePowerCalibrator.AcquirePowerReadingsEx('naPowerMeter','1','True');
Note, the following three commands work fine:
* app.SourcePowerCalibrator.CheckPower(0,80e6)
* app.SourcePowerCalibrator.CheckPower('naPowerSensor_A',80e6)
* app.SourcePowerCalibrator.CheckPower(pschan,80e6) %pschan is defined above
Any help would be appreciated.
Edited by: golfnut on Aug 15, 2012 3:08 PM