NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Split an array in TestStand 2.0

I have a 2D array of numbers, call it rows, and columns. I want to call a sequence that will operate on a single row of the array. Is there a way to pass a row of a 2D array to a sequence in TestStand 2.01?

Because of limitations of the program I'm working on, I'm being made to use Version 2.01, with a process model that further limits my ability do use some features that 2.01 normally has.

Thanks in advance for any help you can provide,
David
0 Kudos
Message 1 of 4
(3,185 Views)
Hi,

The only way is to use a loop and copy the value from the 2D to 1D that you can use to pass to the sequence call. you will have to add another step which has a loop action to create your 1D array. Maybe use a None Adapter.

eg
in your post expression of the step
Locals.Array1D[RunState.LoopIndex] = Locals.Array2D[Locals.RequiredIndex][RunState.LoopIndex]


Otherwise, you are going to have to call maybe a labview adapter step and pickup your 2d array inside your code and return a 1D array. There are examples for all the code types as part of the TestStand examples.

Hope this helps
Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 2 of 4
(3,179 Views)
Thanks. That's pretty much the solution I came up with, but I was hoping there might be a better way.
0 Kudos
Message 3 of 4
(3,173 Views)
Hi,

No, pretty basic when it comes to array manipulation. I generally pop into a labview step if I need to do any array handling.

Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 4 of 4
(3,167 Views)