Passing TestStand Globals to LabView parameters

Hello All,
        We store our operator entered test info in TestStand Globals, and then pass them to LabView parameters.  Is there a way to default the Labview parameters to always have the TestStand Global name?  So we won't have to select those same globals for each test.  Thanks.

Hey Bill,
Thanks for clarifying.  The first option really isn't an option.  It's more of an explanation that the steps should always use the StationGlobals as parameters if when you Specify the Module you set the parameters as StationGlobals.WhateverVariable. 
It's important to note the 4 actions of creating a step-
1- Choose the Adapter (LabVIEW, CVI, C++ etc...)
2- Choose the StepType (PassFail, Action, Numeric Test, String Test etc...)
3- Specify the Module (point the step to the code you want to call)
4- Set the step properties (preconditions, post action, expressions, run options etc...)
In your case you would choose the LabVIEW adapter, Choose the StepType, Specify the Module to point to some LabVIEW code (I'm assuming these are prewritten), and then set some step properties.  Now the issue here is that you want TestStand to automatically assume that you want to pass StationGlobals as parameters to your step.  This is done in step 3 of the process.  However, TestStand cannot assume what to put as the parameters to a LabVIEW module because most LabVIEW modules have different inputs and outputs.  Do all your LabVIEW modules have the same inputs and outputs? 
Option1- If you have TestStand 4.0 or later then you can use Templates.  I really like this new feature of TestStand.  It's very handy because all you do is follow the process to creating a step and then drag that step to your templates window.  Then whenever you want to place a step with the same or very similar setup just drag it from your templates onto your sequence.  This way you don't have to go through the entire process every time.  And the parameters will remain the same.
Option 2- So for the 4 Test StepTypes (Pass/Fail, Numeric Limit, Multiple Numeric Limit and String Value) and the Action step there are something called Code Templates.  A code template is simply a skeleton piece of code that gets created when you click the create VI button in your specify module tab.  This is not new in TS 4.0 but an older feature as well.  These templates are stored here: C:\Program Files\National Instruments\TestStand 4.0\CodeTemplates\NI and are managed by the StepType properties.  I recommend copying them to your C:\Program Files\National Instruments\TestStand 4.0\CodeTemplates\User folder before editing them.  As this is the proper way to do it and you don't lose your default templates.  TS will always look in the User folder first.  If it's not there then it will go to the NI folder.  The names of the folder are pretty intuitive.  Basically you have DefaultLabVIEW.  Which is for the Action Step Type.  Or you have NumericLimitLabVIEW which is for the Numeric Limit Step Type.  Whichever type you want to change the template for then you open that folder and edit the LabVIEW skeleton code to resemble what you want with the correct inputs and outputs.  Then you save it and go into TS and go to your type palette.  No the problem I have here is that you cannot change the parameters for the default NI step types.  So you will have to copy the StepTypes and create your own.  Trust me though- you don't want to dink around with the NI defaults.  It's messier later.  So when you create your own step type you can then edit the properties by Right Click-> Edit Properties.  There should be a Code Template tab.  you can set up everything including the parameters for that code template.  So then the next time you insert a step and click the create VI button from the Specify Module tab it will automatically contain your own parameters.  In your case StationGlobals. 
Ok so it's obvious that Option 2 is not ideal.  But if you have TS 3.5 or older then it's the only way other than copying and pasting steps.  If you want more info on Code Templates go to the TS help and read about them.  Or let me know if you have specific questions.
Hopefully this info will help you out and please let me know if you are confused or need more info.
Best Regards,
jigg
CTA, CLA
teststandhelp.com
~Will work for kudos and/or BBQ~

Similar Messages

  • Write teststand globals from labview

    Hi all,
    i just started using teststand and i am not too familiar with the program up to now.
    What I want to do is, writing teststand station globals from a vi that i started asynchronously. What steps do i need to execute in teststand before starting the vi? A small example would also be great.
    thanks for your help.
    Walter

    When using instruments in LV code modules, the code module itself presents a lock (default execution setting of LV VIs when not changed to reentrant execution).
    So if the instrument is used in a single code module (which is used several times in your TS sequence(s)), there is nothing you have to worry about.
    If the instrument is used in multiple (different) LV code modules (by passing its handle from module to module), you might require to include some locking.
    I recommend you to provide the lock in TestStand. Use the Lock steptype in the synchronization palette to do so.
    Norbert
    CEO: What exactly is stopping us from doing this?
    Expert: Geometry
    Marketing Manager: Just ignore it.

  • How can I programatically modify a teststand sequence global in Labview ?

    Hello,
    I am automating some tasks using Labiew to modify data in a Teststand sequence file. How can I programatically modify the value of a Sequence Global from labview ?
    Thanks,
    Sam

    You have to pass in the TestStand variable RunState.ThisContext to the vi through the connector pane.  I'm not sure about the exact variable name because I don't have TestStand loaded at this time.  But  there is a variable for the sequence context in TestStand and this has to be passed to the vi.  Note that you cannot run the vi stand alone.  You must run it from TestStand in order to get the proper sequence context.
    - tbob
    Inventor of the WORM Global

  • J'aimerais lire ou modifier des variables globales sur TestStand à partir de LabVIEW

    Bonjour,
    J'utilise LabVIEW pour lancer TestStand et j'aimerais avant de lancer la sequence, modifier les variables globales sous LabVIEW.
    Pourriez vous m'indiquer comment faire?
    Merci,
    Cordialement
    Résolu !
    Accéder à la solution.

    Bonjour,
    En cherchant un peu dans l'API de TestStand (TestStand API Poster : http://www.ni.com/pdf/manuals/372844b.pdf)
    On trouve :
    Typically, you use the PropertyObject class to get or set the values of custom step properties, sequence local variables,
    sequence file global variables, and station global variables.
    Ce qui donne :
    Cordialement,
    Da Helmut
    Pièces jointes :
    TestStand Globale.vi ‏11 KB

  • How to force TestStand to ignore LabVIEW errors

    Hi,
    usually where there is an error in the LabVIEW code module TestStand stops and gives a pouup message .
    Is there any way to force TestStand to ignore LabVIEW errors and contiouse testing?
    Thanks

    You can also work more globally - go to the Configure menu item and select Station Options.
    At the bottom of the execution tab, there's a section for what to do on Run-time errors. -> Show dialog, Cleanup, Ignore or Abort.
    Whilst not specific to steps configured to use the LabVIEW adapter (assuming you're mixing some programming languages) that at least get you continuing on to the next step without the dialog.
    If you need to assess if it's specifically LabVIEW modules causing the error, then you need to use the Station, Process Model or Sequence File callback for On run-time error, and the step gets passed as a parameter. That would allow you to work out if the step was LabVIEW specifically and then make a decision as to what to do next.
    Hope that helps.

  • How to read and write data from Excel to TestStand without using LabVIEW VIs

    Hi,
    How can I read in columns of data from Excel into a TestStand array and write columns of data to Excel from TestStand without using LabVIEW VIs?
    I don't think the Property Loader custom step type in TestStand will work because the data I would like to read in from Excel is in a column that is thousands of rows long and the data has to be in the proper format to use the Property Loader to load in an array from Excel.
    Thanks for your help.

    That example does not use LabVIEW and it does about 40% of what you need to do by calling Excel through ActiveX. If you don't know how to use Excel through ActiveX then you'll need to brush up on that.
    http://www.microsoft.com/en-us/download/details.aspx?id=16250
    http://support.microsoft.com/kb/141759
    http://support.microsoft.com/kb/302084
    CTA, CLA, MTFBWY

  • I am facing a problem in passing multiple values as out parameters from fo

    Hi All,
    i am facing a problem in passing multiple values as out parameters from for loop.
    EX:
    i have a select statment inside a loop like.....
    PACKAGE SPEC:
    create or replace PACKAGE EMP_PKG AS
    TYPE TAB_NUM IS TABLE OF SCOTT.EMP.EMPNO%TYPE;
    TYPE TAB_NAME IS TABLE OF SCOTT.EMP.ENAME%TYPE;
    TYPE TAB_JOB IS TABLE OF SCOTT.EMP.JOB%TYPE;
    temp_table TAB_NUM;
    procedure test(temp_TAB_e_no OUT TAB_NUM,
    temp_TAB_e_name OUT TAB_NAME,
    temp_TAB_e_job OUT TAB_JOB);
    END EMP_PKG;
    PACKAGE BODY:
    create or replace PACKAGE BODY EMP_PKG AS
    v_e_no NUMBER;
    procedure test(temp_TAB_e_no OUT TAB_NUM,
    temp_TAB_e_name OUT TAB_NAME,
    temp_TAB_e_job OUT TAB_JOB) IS
    BEGIN
    select EMPNO bulk collect into temp_table from emp;
    for i in 1..temp_table.count loop
    v_e_no := temp_table(i);
    select empno,
    ename,
    job
    into temp_TAB_e_no(i),
    temp_TAB_e_name(i),
    temp_TAB_e_job(i)
    from emp
    where empno = v_e_no;
    end loop;
    end test;
    END EMP_PKG;
    PROBLEM FACING IS:
    I am expecting all rows returning from bellow select statment ...
    select empno,
    ename,
    job
    into temp_TAB_e_no(i),
    temp_TAB_e_name(i),
    temp_TAB_e_job(i)
    from emp
    where empno = v_e_no;
    But,while running the SP , i am getting error like
    ORA-06531: Reference to uninitialized collection
    ORA-06512: at "SCOTT.EMP_PKG", line 16
    why i am not getting all values as out parameters.please provide a solution for me.
    Thanks in advance my friend.

    user9041629 wrote:
    Hi All,
    i am facing a problem in passing multiple values as out parameters from for loop.
    EX:
    i have a select statment inside a loop like.....
    PACKAGE SPEC:
    create or replace PACKAGE EMP_PKG AS
    TYPE TAB_NUM IS TABLE OF SCOTT.EMP.EMPNO%TYPE;
    TYPE TAB_NAME IS TABLE OF SCOTT.EMP.ENAME%TYPE;
    TYPE TAB_JOB IS TABLE OF SCOTT.EMP.JOB%TYPE;
    temp_table TAB_NUM;
    procedure test(temp_TAB_e_no OUT TAB_NUM,
    temp_TAB_e_name OUT TAB_NAME,
    temp_TAB_e_job OUT TAB_JOB);
    END EMP_PKG;
    PACKAGE BODY:
    create or replace PACKAGE BODY EMP_PKG AS
    v_e_no NUMBER;
    procedure test(temp_TAB_e_no OUT TAB_NUM,
    temp_TAB_e_name OUT TAB_NAME,
    temp_TAB_e_job OUT TAB_JOB) IS
    BEGIN
    select EMPNO bulk collect into temp_table from emp;
    for i in 1..temp_table.count loop
    v_e_no := temp_table(i);
    select empno,
    ename,
    job
    into temp_TAB_e_no(i),
    temp_TAB_e_name(i),
    temp_TAB_e_job(i)
    from emp
    where empno = v_e_no;
    end loop;
    end test;
    END EMP_PKG;
    PROBLEM FACING IS:
    I am expecting all rows returning from bellow select statment ...
    select empno,
    ename,
    job
    into temp_TAB_e_no(i),
    temp_TAB_e_name(i),
    temp_TAB_e_job(i)
    from emp
    where empno = v_e_no;
    But,while running the SP , i am getting error like
    ORA-06531: Reference to uninitialized collection
    ORA-06512: at "SCOTT.EMP_PKG", line 16
    why i am not getting all values as out parameters.please provide a solution for me.
    Thanks in advance my friend.Probably not a bad thing that this isn't working for you.
    This is a horrible way to return the contents of a table.
    Are you doing this for educational purpose, or ... what is your goal here? If you just want to return a result set to a client you'd want to look in to using a REF CURSOR and not a bunch of arrays combined with horribly procedural (slow) code.

  • How can i find all global variable and parameters in a form?

    I don't know name of global variables and parameters,but i want get their name and value .
    how can i do? who can help me?
    Thank you.
    Daniel Liang
    2007.1.19

    no problem. As Francois said you can't do it programmatic in runtime.
    But when you use the debug-mode you can see each global with name and value.
    By the way: It's not good to not know all the globals in your application. This is one of the most important things you have to write down for your app. Create a wiki for such informations, so that all developer can share their information.

  • Tcode for global idoc interface parameters

    hi,
      can any one say me the tcode for global idoc interface parameters.

    Hi,
    Welcome to SDN.
    check this link might help you.
    tcodes for ALE
    Regards,
    Amit
    Reward all helpful replies.

  • Passing Abap Variants as Application Parameters

    Hello.
    I have searched extensively trying to find documentation for passing ABAP variants as application parameters. For example, I am creating an R/3 iview calling the transaction IW59 (display service notifications)where I am trying to use an existing ABAP variant that has the value of BV. There are no screen fields that I can find.
    Is there a solution to this? Any help will be greatly appreciated.
    Best Regards,
    Pete Horan

    Hi,
    We've encountered the same problem (we think). We want to open a webgui transaction in EP 5.0 with a given variant. What do we need to input in the field "additional dynpro parameters" for this to work? We've tried "VARIANT=", but this doesn't work. We've also set the parameter "process first screen automatically" to "true".
    has anyone experienced this problem before? Any help appreciated!
    Regards,
    Hans Petter Bjørn

  • Pass 2D array from LabVIEW to C# problem

    Hi , I have made a dll using .net assembly to use my labview code in c# . I can easily pass string , numerical and 1D arrays from labview to c# and vice versa, but when I want to read back 2D U16 array from Labview in c# I get the following exception although they have exactly the same type (ushort)
    Cannot widen from source type to target type either because the source type is a not a primitive type or the conversion cannot be accomplished.
    Could you please let me know how should I pass 2d array from labview to c#
    Thanks

    If all else fails, you could pass n 1D arrays across and then put the original 2D array back together. That's probably how the computer would do it behind the scenes, anyway.
    Cameron
    To err is human, but to really foul it up requires a computer.
    The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
    Profanity is the one language all programmers know best.
    An expert is someone who has made all the possible mistakes.
    To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):
    LabVIEW Unit 1 - Getting Started
    Learn to Use LabVIEW with MyDAQ

  • Article: Functional Globals in LabVIEW 8.5 - No Loop, No Joke

    Hello Everyone,
    I've written another article on my blog:
    Functional Globals in LabVIEW 8.5 - No Loop, No Joke
    I hope you find it interesting
    Thanks,
    -Jim
    Message Edited by Jim Kring on 09-07-2007 08:24 AM

    Thank you for your attention!
    I've opened the fixed vi and all seems to be ok, but in few mouse click all messed up again causing strange floating wire and a LV crash.
    If you are brave please try the following procedure (save and close all of your work..!):
    Open your fixed vi.
    CTRL-E to display the block diagram.
    Rigth click on the upper (DBL) feedback node and change it to "Globally Initialize".
    Right click again on the same feedback node and select "Move Initializer One Loop Out".
    Select the feedback node, the "+", the "+1" and the other (blue, INT32) feedback node.
    Then perform the "Horizontal Centers" alignement.
    (in my case) voila! Move one of the 2 feedback node and see what happen....
    Now try to close and save the vi.
    I run LV on a NI PXIe-8106 so I think that this kind of hw is fully compatible with NI software... :-)
    I suspect that in this case the problem is not at a graphic level but reflect a corruption of internal data LV data.
    Attachments:
    Broken wire.jpg ‏54 KB
    Error3.jpg ‏60 KB

  • Opening TestStand Ref from LabView sometimes fails

    I'm having an intermitten problem when opening a TestStand reference from LabView.  The error explaination just says, "LabVIEW:  (Hex 0x80004005) Unspecified error."  Attached is a little vi that can reproduce the problem when set to run continuously. 
    Any idea on how to fix this?  Thanks a lot.
    Note that because of compatibility requirements I have to use TestStand 2.0 with LabView 7.1.
    Attachments:
    TS_Ex.vi ‏24 KB

    Attached is a screen shot of the error message.  This is one of at least 2 error messages.  I will get the other one when I can get time on the equipment.  Right now, I would like to get the error log (mentioned in the screen shot), but I can't find it.  Where should it be?
    Unfortunately, the equipment is being shared and I haven't received time to debug it more.  But this is what I have seen. 
    Trying to Highlight Execution with breakpoints seemed to point the vi closing the reference to TestStand as the source of the error message.  Using the Simplified TestStand Operator Interface vi that came with TestStand, and some fake tests, we did not have this error.  Only when we use our customized OI with dynamic test sequence generation do we get the error.  This error doesn't occur with LabView 6.1.  So I think it may be another incompatibility between LV 7.1 and TS 2.0.
    Thanks for your help.
    Attachments:
    Exit-Crash-1.doc ‏24 KB

  • Execution of TestStand-Sequence in LabVIEW via TS-API: Different Execution times for same sequence

    Hello Forum-Members,
    I have a problem concerning the execution of an TestStand-Sequence in LabVIEW. I have created a VI that offers the ability to choose a TestStand-Sequence-File and then executes the sequence using the TestStand-API. The implementation is based on an example in C++-Application found following this link:
    http://forums.ni.com/t5/NI-TestStand/Unreleased-references-using-engine-API-in-C/m-p/2927314#M46034
    The implementation works quite solid in case the VI is executed the first time. The VI processes the chosen sequence in a acceptable duration.
    But in case the execution is started a second time, the execution of the sequence takes ca. 30sec more than in the first case.
    Until now I have not found a solution and hope someones got a hint concerning this problem...
    I am using LabVIEW 2013 and TestStand 2013.
    I have attached my own VI, a sample sequence with a small sample VI, so you can reproduce the problem.
    Kind regards,
    TobiKi
    Solved!
    Go to Solution.
    Attachments:
    Exe-TestStand-Sequence.vi ‏25 KB
    Sequenz.vi ‏8 KB
    Test-Sequenz.seq ‏5 KB

    Hi Norbert,
    first thanks for your answer.
    What would be a reasonable way to replace the "Execution.WaitForEndEx"? My first idea is to get the respective thread of the execution and use the "Thread.WaitForEnd".
    To clarify my problem:
    The execution of the sequence itself takes longer time and so the execution of the calling VI. I have attached pictures of the log file of the first and second execution.
    Further I don't get any dialog popups during the shutdown of TestStand. (I have activated the "ReportObjectLeaks" using the "DebugOptions") While developing the attached VI I've gotten several popups. But these popups disappeared after closing all references.
    Maybe you have another hint how to locate the problem.
    TobiKi
    Attachments:
    FirstExecution_20-08-2014.png ‏16 KB
    SecondExecution_20-08-2014.png ‏16 KB

  • TestStand Full Featured Labview OI - Documentat​ion?

    Can anyone point me to any documentation/examples out there for the TestStand Full-Featured Labview OI? I have tried looking just about everywhere and can't seem to find any good documentation/explainers on how the OI works and how to customize it. I am new to TestStand OIs and am trying to create an OI that allows me to run up to 6 different UUTs independently at the same time. I can't figure out how to wire in each individual Execution Entry point and am looking for examples and/or documentation. I also need some help with Progress bars and test status indicator LEDs.     

    Below is an example front panel of what I am trying to accomplish. Most of the controls are not connected of course :-). I am trying to have one window with 6 different executions shown within it. Each execution would be seperate from one another and you would be able to view each just by clicking on the tab for that particular test fixture. The only thing that would be common is that each execution would be running the same sequence file. The individual test fixtures could be at different points in the test sequence and could have different start and stop times for each. For instance....test fixture #1 could be loaded with a UUT and started into test then while it is running test fixture #5 could be loaded with a UUT and started into test. In the meantime when test fixture #1 has finished testing I could load another UUT into test fixture #1 while test fixture #5 is still running. etc etc
    Attachments:
    MultiUUT.JPG ‏155 KB

Maybe you are looking for