Quantcast
Channel: NI TestStand topics
Viewing all 6524 articles
Browse latest View live

C# teststep: How to pass Visa reference to correct instrument?

$
0
0

Hello,

in C# i created a DLL for an instrument with functions like Initialize, SetVoltage, Close.

In the Initialize function i create the object for this session with:

            RM = new ResourceManager();
            Instrument = new FormattedIO488();

 

Now i put the Initialize function in TestStand 2014SP1 as a .Net-Module-NumericLimitTest.

When opening the properties of my new step in the Type-Editor then there is a button "Default Module" where i can select the function of the C#-DLL.

 

All paramaters are shown (like VISA-Address) and also an additional parameter "Return Value" Object Reference" OUT which was added by TestStand.

-> I save this value in a StationGlobal.

 

Question is now:

If i have more than one instrument of the same type (means two or more Initialize-calls) how can i pass the saved references to the next function (SetVoltage) so that is executed on the correct instrument?

 

Thanks for help


How to use MultiNumericLimitcheck for custom c#-teststep

$
0
0

Hello,

i have a c#-teststep that has two returnvalues that i want to limitcheck.

 

Currently i put them into Step.Result.Measurement[0].Data and

Currently i put them into Step.Result.Measurement[1].Data

 

But what to do then? How can i add a limitcheck?

 

Thanks for help

UI Message Event --> Property Objects not released

$
0
0

Hi,

 

I've been working on my custom OI for a while and I'm already using UserMessages to send data to my LabVIEW OI successfully. Everything is runing quite smoothly.

Today, I tried also to implement some some functionality for the build in UI Messages (e.g. UIMsg_ModelState_BeginTesting) which also works. But now TestStand gives me an error when shutting down.

nonreleased.png

 

Is there anything special I have to consider when using this messages? Haven't had this problems when only using UserMessages.

One more thing: since I'm still implementing some other things, I'm starting the UI from the development enviroment. When I'm closing the LV project after the above error has occured, the following one comes up:

runtime.png

 

Windows consequently reports LabVIEW as unresponsive and asks how to go on.

 

I'm using (still) LV2013SP1f5 and TestStand 2013 SP1. The UI makes heavy use of the Actor Framework. The test sequence I'm running is just a generic that keeps sending messages to the OI

 

Anybody any ideas?

 

Cheers

Oli

 

 

 

single pass status banner

$
0
0

is there any good reason why the "Pass/fail" status banner is not shown in "single pass" mode?

There is a precondition in the post uut - status banner step, checking if it's "Test UUTs" or "Single Pass".

 

Is there a way to show the banner without changing the model, but using a callback tp post uut or so ?

 

br

Nikolaj

How to save binary array result to database

$
0
0

I want to save an image file to the results database.

I imagine that this is a common task.  I would appreceate if someone could send me a working example.

 

I created a custom step with a numeric array in the Step.Results folder.

I created a DLL (C#) to read the file contents and return it to TestStand as a byte array.

When the step runs the array is populated - OK so far.

 

ISSUE#1 - At the end of the sequence the process model hangs a very very long time at the step to write to report.  I am using the ATML v6.01 report.

   I experimented with tiny image files and it hangs a much shorter time.

The report is not displaying my data.  Not sure why it is processing it - taking a long time.

Q1) How do I prevent the report from hanging on my array of data?

 

ISSUE#2 - the data is not going in the database.

I am using a database very similar to the default NI database - Generic Recordset (NI)

I added fields for our customer but the PROP_RESULTS and the PROP_BINARY part of the schema is identical.

I am getting a record in the PROP_RESULTS  for my test step but nothing is going in the PROP_BINARY.

Per the schema, any property object that is an arry type should be added to the PROP_BINARY table.

 

Below is an image of the properties for this custom step.

Attached is a sample sequence file with the step in use (provides a copy of the custom step type). 

  The area of concern is moving the data form the step to the database and nto hanginup the local report.

  I did not include the DLL that collected the array from the file.

 Custom Step Properties - Numeric Array in Step Results.PNG

 

 

How to set error-cluster in postexpression?

$
0
0

Hello,

i created a c#-driver that returns a 0 for pass or -1 for fail in all functions "int MyFunction()".

Now i am using this functions for teststeps.

 

Question is: How can i use this returnvalue to set the error-cluster?

So that a -1 creates an error.

 

I think this can be done in the post-expression somehow.

How do i put a

if (returnvalue == -1)

{

Result.Error.Code = 10100

Result.Error.Msg = "Error occured"

Result.Error.Occured = True

}

 

Thanks for help

TestStand 1 course excercise 8-3 solution hangs when using batch model

$
0
0

Hi,

I am trying to run TestStand 1 on-line course exercise 8-3 solution (unmodified) and it just hangs on the first step after the Lock step - a message popup.. If I run the same sequence using sequential or parallel models, it runs just fine.

TestStand itself does not hang, only execution of the sequence. No errors. Can this be caused by wrong station settings?

Please advise.

 

Does not work on: NI TestStand 2014 SP1 (14.0.1.103) 32-bit

Works on: TestStand 2014 SP1 (14.0.1.103) 64-bit

How to integrate Ag34980 into ni switchexec?

$
0
0

Hello,

i installed Switchexec 2015, IVI Shared Components 2.3, IVI 34980-driver om a Windows 7 system.

The 34980 will have some modules like 34932, 34937, ....

Everything will be used under TestStand later.

 

How do i start now?

Currently i startetd NI MAX and see that there is an entry "NI Switch Executive Virtual Devices"

In there is a "SwitchExecutiveExample" with two "SampleMatrix1 and 2".

 

These two "SampleMatrix 1 and 2" can be found unter IVI drivers -> Logical Names and point o Drivers Sessions -> Simulated8x8Matrix.

 

The example-routes are visible in TestStand so everything is correct installed.

 

How do i now setup my 34980-modules in here?

I tried to watch the firststart-videos on the ni-website but they dont play.

 

Is there something like a first-steps-pdf?

 

Thanks for help


OLE Automation Error: Class not registered

$
0
0

We were upgrading a Windows 2000 PC to Windows XP and received the following error when we ran the test program:

 

OLE Automation Error: Class not registered

 

No other information is provided.  This is a distrbuted test program that installs through an executable. 

 

It appears that the Test Stand version it was written with is for Windows 95/98/NT, Version 1.0

 

Any ideas as to how to get the program to run on the new PC/operating system?

TestStand memory issues to look out for?

$
0
0

Hi All,

 

I have an application which runs 32 parallel tests, these tests are very long (45-60days). There is some sort of memory issue that I am encountering which is causing memory usage to increase by roughly 3-4MB per day.

 

Here's what i've done so far.

 

  • Not using any built in reporting, using LV Database toolkit for reporting. 
  • Disabled result recording for every step.
  • Disable Result Recording for All Steps in "Sequence Properties"
  • Gone through every VI and followed NI best practices as outlined here.
  • Ensured that all references are closed in my modifed OI.
    • Using the simplified OI, modified to use UI message events, which I then poll data from the sequence using Teststand "GET" function in LV.
    • OI uses subpanels which are started asynchronously

 

Are there any particulars about TestStand that may be causing this issue? Possibly some setting that I have overlooked?

 

 

I am using LabVIEW 2014 SP1 and TestStand 2014 both 32-bit.

 

Thanks in advance!

How to switch report-DLL in modell?

$
0
0

Hello,

i am using TestStand 2014SP1.

When i click in the menue-bar on Configure + "Result Processing" then i can select in a popup between Report,Database or Offline.

Currently Report is selected. There i click on the options-icon on the right side.

 

Question is now:

In the model I want to switch between two different layouts (default layout or from a custom dll).

Is this possible? Or is the only way to change report-settings in this popup-form?

 

Thanks

Switching: How to use NI Switchexec without predefining routes?

$
0
0

Hello,

i am using TestStand 2014SP1 and Ni SwitchExec. In there i imported a 4x32 matrix.

How can i use the matrix in TestStand with the names that came with the driver without predefining routes?

 

Something like
Routes to Connect: "VirtualDeviceName.LogicalName.s1m1c1->VirtualDeviceName.LogicalName.s1m1r1".

 

Is this possible?

 

I think there is no way to predefine all possible routes for a 4x32 matrix.

 

Thanks for help

 

step pane custom layout when Test UUTs (F5) is pressed

$
0
0

I have noticed, that when executing a sequence in test-stand the steps pane lay out is different, where some tabs in parallel model are all in one row, while other workstations have them in multiple columns/rows.  I am pretty sure there's got to be a way to control this, but I just don't know how to.  See the pictures attached, if what I am saying isn't clear. 

Tried messing with UI configuration under the Sequence Editor Options, but it doesn't seem to do it for me.

 

Thanks for the Help!

No TS UI controls 2014 SP1 (64 bit) in the toolbox of Visual Studio 2015

$
0
0

I installed

 

  1. Visual Studio 2015 Express
  2. Teststand 2014 SP1 64 bit

I made a sample windows C# forms application with Visual Studio 2015 (64 bit platform) and tried to drag Teststand UI controls on the form, but  there are no Teststand UI controls present in the toolbox of the Visual Studio. (No tab). How can get those controls into my application ?

 

 

Viewing the same execution in two distinct ExecutionView

$
0
0

Hi,

 

I'm buiding a TS Operator interface which can display several distinct execution at the same time (modified // processmodel). Each is displayed in a specific ExecutionView in an independ window. Each ExecutionView is realted to its own ExecView Manager.

 

I'd like to create a another window (Superivsion window) which lists all running executions (within standard TS ListBar) and when I chose an execution from the ListBar it displays the corresponding execution. So I'll have the same execution displayed into two different ExecutionView (each executionview being related to its own executionView Manager).

 

The problem is, when I choose an execution from the ListBar it correctly appears in the supervision window, but it disapears from the other ExecutionView.

So I can't see the same execution into two different windows...

 

Would you have an idea why this is happening ? Any advice on how to achieve this purpose ?


pass Labview results to Teststand while runtime

$
0
0

Hi all, 

 

I am using LabView to sweep across frequency for some tests. I am trying to call a Teststand sequence in the LabView for checking teh limit of each value calculated. I need to integrate this Sequence call within the LabView. I am not sure how to do this. Kindly let me know if you have any ideas. 

 

Nish

How can we avoid RunState.Engine.UnloadAllModules()?

$
0
0

How can we avoid uning RunState.Engine.UnloadAllModules()?

 

Right now I have this in my ProcessCleanup Callback of my MainSequence. However I feel like this is cheating and to me it seems like opening hardware without ever calling the close.

Can this cause issues with threads, references and hardware to hang?

How can VIs be unloaded without issues?

It seems that TestStand have major issues with this one. I would prefer clean code.

 

Thanks

Error in Excel when automating through TestStand

$
0
0

HI All,

 

I am trying to automate the excel through the teststand. When I am trying to add sheet in any worbook by calling AddSheet method , I am getting following error :

"Old format or invalid type library".(attached is the snapshot of error)

 

When i googled it , i found that this is known bug when excel is called through visual studio or any other microsoft programs:

below is the link where i found this information:

https://support.microsoft.com/en-us/kb/320369

 

As per the article , if your excel is in English langugae and the system locale is other than english, it will throw such error.

But I checked the locale of my system..It is english only(control panel .>> Region &Language >> administative >> Language for non unicode programs)

 

Still I am getting this error.

 

Is this is known bug with teststand as well?

Also,does anyone have any idea about the remedy for it? apart from what is mentioned in the link(i dont have option to do that ).

 

thanks

 

 

How can we pass Containers as pointer from one Sequence to another?

$
0
0

I want to create a container of variables (still under development) that is viewable from all sequences without:

  • Having to place it in StationGlobals since it is a project specific list.
  • Copy and pasting the container for parameters for all sequences since the container is still being modified and want to avoid 1000 *.seq file changes when 1 variable is added or removed.

 

Another option would be to have a custom *.ini file similar to globalstations.ini but for a specific project. I don't know how to do this.

 

I'm only using TestStand and LabVIEW.

 

For example if this was in C, we pass a pointer to the massive structure in memory.

 

Thanks

file globals for many sequences

$
0
0

Hello All,

I am using file globals and producing a number of subsequences. I would like to use the same variable names in many of the subsequences. I would like all of the variables to be located in one file only. The structure of the fileglobals file indicatates a number of variables can be associated with its subsequence as I can see < subsequence name> above and below the sequences variables.

 

I dont want to produce a huge list of distinct variable names as this could get difficult to manage and prone to repetition of names.

 

The problem I have found is that when I call property loader it appears to ignore the subsequences section names and only loads the last entry in the file. as follows:

 

sequence file

<seq 1>

name: fred

 

<seq 2>

name: joe

***************

 

property loader action

get seq 1 >> name

***************

 

result

name = joe (expected fred, got joe)

**************

 

I asked property loader to get seq 1 name but it returned the last name... from seq 2

 

Advise Appreciated, Regards Chris

 

 

 

Viewing all 6524 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>