From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How to update a list of current step failures in a custom OI

Anyone have an idea for an efficient way to keep updating a list step failures that have occured during an execution using a custom OI developed in LabVIEW.
 
I would prefer not to modify the sequence callbacks as to allow for use of the default or new models, and just read the values from LabVIEW.
 
My current thinking it to use the Thread.ResultObj.ResultList, however i'm unclear when this object gets updated and if it will fit my needs.  Simply updating off a context object will not work since I do not want to pause my execution after each step.  So I am also unclear on what teststand event should trigger an update.  Attached is an image of one of some of my thoughts thus far.

Message Edited by Dillon G on 03-14-2007 05:26 PM

0 Kudos
Message 1 of 5
(3,020 Views)
Hey Dillon,

There are a lot of ways that you can do what you are wanting, but in order to identify the best way, I need some more information about your application/goal.  What exactly are you wanting to do?  I see from your post that in basic terms you are wanting to send the results of your steps to your OI.  More specifically speaking, why do you want to do this?  What are you trying to accomplish?
Thanks,

Andy McRorie
NI R&D
Message 2 of 5
(2,998 Views)

Andrew,

My final goal is to have a list view that contains all of the failures that have occured during a given execution.  However, I want this list to update while the execution is running and not just read the result list at the end.  Building and laying out the list is not the question, but getting the information for the list (step name, sequence name, status) while the execution is running is.  The main sequence itself contains many subsequences, some of which may have failures that we wish to ignore.  By displaying the failures that have occured thus far the user can choose to terminate the execution if and when they desire.  While the message "failed" is displayed next to a step that failed it is possible that the execution view will scroll to quickly for the operator to read the message, I do not wish to have the system break at every failure.

Now for some background information on my program so far.  I have a pretty large collection of teststand events registered to callbacks in LabVIEW.  This would be my prefered method for handling the collection of this information.  If there existed an event that occured after each step that returned the step result, that would be the ideal solution or the situation I would like to create.  If a solution includes receiving multiple results at once, this could also be handled.

Thanks

//edited for grammar

Message Edited by Dillon G on 03-15-2007 11:57 AM

0 Kudos
Message 3 of 5
(2,989 Views)
Hey Dillon,

It sounds like the best option for you to use would be using UIMessages.  In order to accomplish this, you can override the ProcessModelPostStepFailure callback.  Inside of this sequence call Engine.PostUIMessage to post a custom UI message (code >=UIMsg_UserMessageBase/10000).  You can then register a callback from your OI to handle OI messages.  When the UIMessage is sent, the sequence context will be included.  You can simply update the list in this callback relying on the sequence context for any information you might need.

Here's some great resources for getting started with UIMessages:
http://zone.ni.com/devzone/cda/epd/p/id/3879
http://zone.ni.com/devzone/cda/tut/p/id/4532
http://zone.ni.com/devzone/cda/tut/p/id/2699
Thanks,

Andy McRorie
NI R&D
Message 4 of 5
(2,973 Views)
Andrew,

Thanks for the information.  I was just looking at UImessages a bit ago and I believe that might be an adequate solution.  While not my original vision, not editing sequence fill callbacks, this may be a much cleaner and expandable design.

Thanks
0 Kudos
Message 5 of 5
(2,967 Views)