NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I pass Sequence Context to Labview DLL

I have Labview DLLs that I need to convert to DLLs that can be called from TestStand.  I've prototyped a simply VI and have gotten it to work just fine.  I run into problems when I try to prototype using the Sequence Context type parameter.  When building the DLL from Labview it recognizes the type as IDispatch pointer.  When I call the built DLL from TestStand it recognizes that parameter type and I pass to it "thisContext".  But when I actually run the step, the variables that should be pulled from the sequence context gets nothing.  It's like those variables don't exist.  Example: if, in the VI, i use the SequenceContext to get to a TestStand boolean and use that boolean in a conditional argument that determins a string output, no string is passed to the output indicator.  Can anyone tell me what's going on with passing parameters via sequence context?

 

  

 

 

0 Kudos
Message 1 of 5
(3,564 Views)

Hello,

 

Are you able to verify the value of the boolean before the condition is evaluated by wiring it up to its own indicator as well?  In any event, I would be curious to see a small example that exhibits this behavior because it is my inclination that one case or the other must be accepted, even if it is an inaccurate evaluation of the original TestStand boolean. 

 

One last question, is there a reason that you are passing the sequence context to obtain a boolean from TestStand, rather than just the boolean itself?  Are there other elements of the sequence context that you are trying to manipulate in LabVIEW and want to just pass one parameter?  This should not be a problem, but I wanted to make sure that the simplest method is being employed if at all possible.

0 Kudos
Message 2 of 5
(3,538 Views)
The boolean is being passed from Teststand is a locals variable who's default is True.  I also watch the variable while the sequence is being run.  Also, the existing code i'm working with uses sequence context to pass variables from Teststand to Labview.  I'm converting those top level Labview VIs to DLLs, most of them will use Sequence context to pass variables.  I can recode so that TestStand passes the individual variables but that will be time consuming and it looks like Sequence Context should work straight forward. I've made some screen shots to show what I have.  Please let me know where I'm going wrong.
0 Kudos
Message 3 of 5
(3,489 Views)

Do the details outlined in this resource pertain to your particular situation?  If so, it describes a known issue as well as a workaround for that issue.

0 Kudos
Message 4 of 5
(3,443 Views)

While reviewing the aforementioned resource, I realized that it may be limited to a previous version of TestStand.  As such, I created an example that successfully accomplished what we had been discussing and have attached it below.  It utilizes TestStand 4.1 and LabVIEW 8.6.  Please let me know if you need a different version with respect to either of these environments.

0 Kudos
Message 5 of 5
(3,431 Views)