NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Send Container as parameter to Slave (Remote Computer)

I have to send a container as a parameter to a slave machine. From TestStand I will be forced to use Object Reference.

Using other parameter types like: String, Numbers or Arrays works well, but when I fill the Object Reference with the content of the Container, I get an error.

The error appears when I do the remote call.


Error:

The RPC server is unavailable. Picture attached: Error.PNG 


I dont believe, that RPC server is unavailable, because if I sent an empty Object Reference there is no issue. Also when I sent Strings or Numbers as Parameters, there are no problems.


I tried to pass the value as "value" or "reference" but no deference. I think it should be by "reference".


I also tried to fill the Object Reference in different ways:

Locals.BASE_CFG_OR = RunState.ThisContext.AsPropertyObject.FileGlobals.BASE_CONFIG.GetPropertyObject("",0)

and then assign Locals.BASE_CFG_OR to the Object Reference parameter.


or


Using Parameter.BASE_CONFIG = RunState.ThisContext.FileGlobals.BASE_CONFIG.GetPropertyObject("",0)


FileGlobals.BASE_CONFIG is the container I want to send to the slave machine.


I'm pretty sure assigning the container directly should not work. Like:

Parameter.BASE_CONFIG = FileGlobals.BASE_CONFIG.


So my questions are:

•Do I have to use Object Referece to send Containers as Parameters?

•How do I fill properly the Object Reference with the data from FileGlobals.BASE_CONFIG(type = container)?

0 Kudos
Message 1 of 9
(1,227 Views)

Attached is my Master and Slave sequence and an example what I'm trying to do.

Hope this will help to understand my issue.

Download All
0 Kudos
Message 2 of 9
(1,170 Views)

I see no reply so far. Is the problem description clear? If not, please let me know what is unclear.

0 Kudos
Message 3 of 9
(1,128 Views)

I'm not really have much knowledge of remote exections.... yet to me it doesn't make sense to send a reference from a local computer to a remote one. 

The reference is in its essence just a handle / pointer (call it whatever you like) to the local memory. 

Enabling a remote computer direct access to local memory is a security  issue

 

Why does TestStand "force" you to use a reference?

0 Kudos
Message 4 of 9
(1,115 Views)

If I set the BASE_CONFIG parameter on slave side as type Container, on master side the step with the remote call will have the red exclamation mark with following information:

 

One or more of the parameters for this sequence call are property containers. Because TestStand converts property container arguments to object references for remote sequence calls, you cannot use expressions that refer to the subproperties of the arguments in the remote sequence. Use the Property Object class in the TestStand ActiveX API to access the subproperties of the arguments in the remote sequence.

0 Kudos
Message 5 of 9
(1,104 Views)

Just a shot in the dark....

 

can you try to use the following expression for the assignment  in your master sequence

 

Locals.BASE_CFG_OR = ThisContext.AsPropertyObject.EvaluateEx("FileGlobals.BASE_CONFIG",0)

 

 

0 Kudos
Message 6 of 9
(1,090 Views)

Same error:

The RPC server is unavailable.

 

Additional information:

I have another container which I send from slave to master and this one is not having issues.

 

Parameter type is Object Reference(By reference)

Name UB7_CFG

 

And this is how I assign the Container to the Parameter

Parameters.UB7_CFG = RunState.ThisContext.FileGlobals.UB7_CFG.GetPropertyObject("",0)

0 Kudos
Message 7 of 9
(1,066 Views)

Maybe it would help me to understand the issue, if someone can explain me this warning:

 

One or more of the parameters for this sequence call are property containers. Because TestStand converts property container arguments to object references for remote sequence calls, you cannot use expressions that refer to the subproperties of the arguments in the remote sequence. Use the Property Object class in the TestStand ActiveX API to access the subproperties of the arguments in the remote sequence.

 

I do understand the first part. TestStand is converting Container to object references when using remote sequence calls. 

 

But the second part is unclear to me:

you cannot use expressions that refer to the subproperties of the arguments in the remote sequence.

 

What are subproperties? For me it sounds like an element in the container. 

0 Kudos
Message 8 of 9
(968 Views)

I dont want to be annoying, but I really struggle to get it running. 

0 Kudos
Message 9 of 9
(841 Views)