NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

deifining a global batch specification

Hello,

 

I am trying to use the batch specification step to make a global batch accessible outside of my process.

 

According to the documentation, if you use an asterisk (*) as the first character in the name, it should work. I have attached a test sequence to illustrate what I try to do that's using the batch model.

 

When I am adding the thread to the batch, all threads hang. It is not even possible to terminate them and I have to kill Teststand and restart. If I remove the asterisk in the name of the batch, then it does not hang, but I don't have global visibility then.

 

Any idea or workaround?

 

Thanks and regards,

Loic

 

PS: I am using teststand 4.1.1

 

 

 

 

0 Kudos
Message 1 of 6
(4,123 Views)

Hello Loic,

 

Is the attached sequence file representative of your application? Or are you trying to modify the process model directly with these steps? The reason I ask is because the process model typically creates the batch in the background.


Regards,
Glenn
0 Kudos
Message 2 of 6
(4,078 Views)

Hello Glenn,

 

Well I intended to have this file representative of my application.

 

In fact, what I am trying to do is to make a sort of "batch of batch" test system: there will be 5 sets of X UUTs. Each set of X is a batch that has some dedicated instruments to this set. In addition, all sets have to synchronize their testing since there is a PSU and 2 extra instruments shared between all sets.

 

I started with the batch model and made a sequence to control one set. That's fine. But now I want to launch 5 of the sequences for each thread in parallel but still synchronize their access to the global instruments. That's where I would have like to define a batch that is "aware" of all threads at the same time, so I could define some batch section where only one thread would trigger the shared PSU for instance. I tried to have a sequence with no process model launch those 5 execution in parallels and it works. I tried to make some custom "global" batch section with locks, RendezVous, stationglobals and flow control but it is quickly a mess.

 

An alternative would be to launch one batch sequence for all the UUTs and handle the instruments dedicated to one set in an array but it is a bit tricky to handle when one or more set of UUTs is disabled. Well, there is probably no easy solution to the problem anyway... 

 

Thanks,

Loic 

 

 

0 Kudos
Message 3 of 6
(4,061 Views)

It sounds like you want to run a set of UUTs as a batch, and then have the batches run as parallel. If that is the case, I recommend running the main sequence using the ParallelModel and the subsequence as a new execution using the BatchModel.

 

 MainSequence.PNG

 

SeqCallAdvSet.PNG


Regards,
Glenn
Message 4 of 6
(4,044 Views)

Loic -

 

It's important to know that threads only adhere to batch synchronized sections within their specific batch specification. Thus, when implementing Glenn's recommended approach, rather than using a batch synchronized section for your PSU and other two instruments, you should use one of the other types of Synchronization objects. For example, instead of a Serial Batch Synchronized Section you would use a Lock.

 

Attached is an example sequence file that demonstrates this approach.

 

Hope this helps.

Message Edited by Manooch_H on 12-03-2009 08:43 AM
Manooch H.
National Instruments
Message 5 of 6
(4,028 Views)

Thanks for your replies. I will try this way.

 

Best regards,
Loic 

0 Kudos
Message 6 of 6
(4,017 Views)