NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQmx task : In MAX or in lvproj?

Solved!
Go to solution

Experts,

 

What are the benefits to declaring the DAQmx tasks in either the lvproj or in MAX?

 

My question arises as I am trying to call a test VI from within TestStand, and when the DAQmx task constant is declared in the project (lvproj) that holds the test VI, it does not execute properly, saying cannot find the reference or something.

If I change the DAQmx task to be a global task from within MAX everything works as expected.

 

What is the best-practice for doing these kinds of things?

 

Many thanks

nrp

0 Kudos
Message 1 of 6
(3,456 Views)
Personally, I don't see an advantage of either. I always create the task in the LabVIEW program with physical channels, scales, and whatever else is required. I've never used the project to store a task but if I don't store anything in MAX, there is nothing to import when I deploy and I never have to worry about someone going into MAX and screwing around - innocently or not.
Message 2 of 6
(3,451 Views)

Thanks Dennis,

 

I see your logic. My thought was thought that it is a bit easier from a project/code management point of view to have the task defined only once somewhere, and then used where necessary.

 

Trouble is, I am a rookie when it comes to TestStand, so am having to figure everything out on the fly, no time for training courses either unfortunately 😞 

0 Kudos
Message 3 of 6
(3,445 Views)
Solution
Accepted by topic author Neil.Pate

TestStand currently does not support executing VIs in the context of a project. So unfortunately, we expect the behavior you see where calling a VI that uses a DAQmx task defined in a project does not work. For now, if you do want to store your task configuration outside of source code and you want to use such tasks from TestStand, you must store them in MAX.

 

We are looking into adding support for executing VIs in the context of a project in a future version of TestStand.

 

David Rohacek

National Instruments

Message 4 of 6
(3,433 Views)

Thanks David.

 

I am primarily a LV developer, and have gotten so used to the concept and benefits of the lvproj it is difficult to live without it now. Fortunately the work around is reasonably painless.

 

One thing I do wish for though was to be able to group tasks in MAX into virtual folders like you can in a lvproj, I feel it makes the management much easier.

 

It would also be great to be able to display the lvproj in the TestStand project workspace. When  I first discovered these a few days ago I though oh cool, but was then quite disapointed when I could only add individual VIs and not my entire project (which has several LV libraries and FPGA code). TestStand 5 maybe? 🙂

0 Kudos
Message 5 of 6
(3,420 Views)

Hi, I have been using teststand for several years now, on some of my past projects i have created the DAQmx tasks dynamically (sequencefileload callback), then i delete them when closing the sequence. reason being due to several test packages on one system which would mean 100's of saved tasks in MAX.

0 Kudos
Message 6 of 6
(3,380 Views)