我的C ++有点生疏,但你需要做的是相当于以前的串行轮询(SPOLL),现在在C ++中执行该命令的命令是viReadSTB。如果你在3458A手册中查找SPOLL你可以看到
如果使用viReadSTB命令,将获得的结果。
我会试着为你举一个例子,但这可能需要一段时间,所以我想我现在会分享这个。
我会尽快发布一个例子。
如果你在签证文件中查找viReadSTB,你可以找到更多。在我的3458A程序中,我通常命名我的vi,Inst_dmm。
我计划命名我将存储结果SPOLL的变量。
因此,我的C ++代码的一小段内容很可能如下所示:short SPOLL; viClear(Inst_dmm);
viPrintf(Inst_dmm, “复位 n”);
viPrintf(Inst_dmm,“结束总是 n”); viPrintf(Inst_dmm,“TEST n”); //等待45秒,我不记得在C ++中等待你的C ++程序员的正确上下文
ll可能会回想一下如何正确执行此操作(Inst_dmm,& SPOLL);然后检查viReadSTB的结果是否报告3458A的某种IF语句已完成测试。希望这有助于您入门。
你以前用C ++编写过3458A程序吗?
以上来自于谷歌翻译
以下为原文
My C++ is a bit rusty, but what you need to do is the equivalent of what used to be a serial poll (SPOLL), the command to do that now in C++ is viReadSTB.
If you look up SPOLL in 3458A manual you can see the results you will get if you use the viReadSTB command. I'll try to throw an example together for you but that may take awhile so I thought I would share this now. I'll try and post an example soon. If you look up the viReadSTB in the visa documentation you can find out a little more.
In my 3458A programs I generally name my vi, Inst_dmm. I plan on naming the variable that I will store my result SPOLL. So a small snippet of my C++ code will most likely look like this:
short SPOLL;
viClear(Inst_dmm);
viPrintf(Inst_dmm,"resetn");
viPrintf(Inst_dmm,"end alwaysn");
viPrintf(Inst_dmm,"TESTn");
//wait 45 seconds, I don't remember the correct context to do a wait in C++ if your a C++ programmer you'll probably recall how to do this properly
viReadSTB(Inst_dmm, &SPOLL);
Then some sort of IF statement that checks if the result of the viReadSTB is reporting the 3458A has completed the test.
Hopefully that will help get you started. Have you ever written a 3458A program in C++ before?
我的C ++有点生疏,但你需要做的是相当于以前的串行轮询(SPOLL),现在在C ++中执行该命令的命令是viReadSTB。如果你在3458A手册中查找SPOLL你可以看到
如果使用viReadSTB命令,将获得的结果。
我会试着为你举一个例子,但这可能需要一段时间,所以我想我现在会分享这个。
我会尽快发布一个例子。
如果你在签证文件中查找viReadSTB,你可以找到更多。在我的3458A程序中,我通常命名我的vi,Inst_dmm。
我计划命名我将存储结果SPOLL的变量。
因此,我的C ++代码的一小段内容很可能如下所示:short SPOLL; viClear(Inst_dmm);
viPrintf(Inst_dmm, “复位 n”);
viPrintf(Inst_dmm,“结束总是 n”); viPrintf(Inst_dmm,“TEST n”); //等待45秒,我不记得在C ++中等待你的C ++程序员的正确上下文
ll可能会回想一下如何正确执行此操作(Inst_dmm,& SPOLL);然后检查viReadSTB的结果是否报告3458A的某种IF语句已完成测试。希望这有助于您入门。
你以前用C ++编写过3458A程序吗?
以上来自于谷歌翻译
以下为原文
My C++ is a bit rusty, but what you need to do is the equivalent of what used to be a serial poll (SPOLL), the command to do that now in C++ is viReadSTB.
If you look up SPOLL in 3458A manual you can see the results you will get if you use the viReadSTB command. I'll try to throw an example together for you but that may take awhile so I thought I would share this now. I'll try and post an example soon. If you look up the viReadSTB in the visa documentation you can find out a little more.
In my 3458A programs I generally name my vi, Inst_dmm. I plan on naming the variable that I will store my result SPOLL. So a small snippet of my C++ code will most likely look like this:
short SPOLL;
viClear(Inst_dmm);
viPrintf(Inst_dmm,"resetn");
viPrintf(Inst_dmm,"end alwaysn");
viPrintf(Inst_dmm,"TESTn");
//wait 45 seconds, I don't remember the correct context to do a wait in C++ if your a C++ programmer you'll probably recall how to do this properly
viReadSTB(Inst_dmm, &SPOLL);
Then some sort of IF statement that checks if the result of the viReadSTB is reporting the 3458A has completed the test.
Hopefully that will help get you started. Have you ever written a 3458A program in C++ before?
举报