我如何将TestStand 的值传到LabVIEW 的簇中?
主要软件:
主要软件版本:
主要软件修正版本:
次要软件: N/A
问题: 我的LabVIEW 程序中有一个簇<Cluster>,我想把TestStand的值传进去。当我设定了参数并将它送到我的LabVIEW模块时,出现了以下的错误信息:
-17311; Could not accept the parameters passed in<不能接受传入的参数>。 为何发生这种错,我怎样才能将对象传到LabVIEW的簇中?
解答: 要想将参数传到 LabVIEW,要首先在数据类型属性〈Data Type property>对话框中的Cluster Passing 页上开启 cluster passing 的选项。
因为我们只能通过自定义数据类型〈custom data type〉才能启动data type 的属性,所以我们必须先建立一个custom data type ,然后才能将对象〈object〉传到 LabVIEW 的簇中。
下面的例子展示了设置custom data type最快的方式,并且利用这个data type 将参数传到LabVIEW 模块〈module〉中。
- 在sequence 中加入一个action 的step,然後调用一个包含cluster 输入的 LabVIEW 模块。
-
在Step Settings 面板中,选择Module 分页,然后在参数列表的Type 下面按Create Custom Data Type... 按键。

-
为自己创建的custom data type 命名,然后在
Create Custom Data Type From Cluster 对话框中点击
Create 按钮。

-
接下來,在参数面板〈Parameter〉中右键选择
insert parameter » Types» < Your _Custom_Type> 来产生用来传输参数的custom type,为这个参数命名。

现在,已经可以将参数从TestStand 中传到LabVIEW 的簇中。在data type property 的对话框中,
cluster passing 的分页里面的 cluster passing选项已经自己启动了。
相关链接:
附件:
container.seq
container.vi
报告日期: 10/17/2007
最近更新: 10/31/2008
文档编号: 4EGISTA0
Other Support Options
Ask the NI Community
Collaborate with other users in our discussion forums
Request Support from an Engineer
A valid service agreement may be required, and support options vary by country.