Get DAQmx tasks parameters

I've created in MAX 4.0 some DAQmx tasks to control diferent digital outputs bits (I attach a picture of it). I have to develop a TestStand step type with LabVIEW 7.1 in edit mode able to select any of this predefined tasks and show the bits correspondence (following the picture it would be for example "DigitaOut4 -> Dev1/por0/line2"). Is there some method to get all those parameters? Does somebody has a small example? Thanks in advance.
Mackemann
Attachments:
MAX DAQmx Tasks.JPG ‏62 KB

You can get all of this information from DAQmx property nodes. I wrote a quick example and there are probably more on either the LabVIEW or DAQ boards.
Message Edited by Dennis Knutson on 03-30-200602:56 PM
Attachments:
DAQmx Properties.JPG ‏30 KB

Similar Messages

  • Why can I not use the channel name, which is obtained from the function of DAQmx Task, as the input of the channel name for the function of Get Channel Information of DAQ?

    Why can I not use the channel name, which is obtained from the function of DAQmx Task, as the input of the channel name for the function of Get Channel Information of DAQ?

    Not a lot of details here, but my guess is this isn't working for you because you are wiring in the task to the Active Channels Property and not the actual Channel Name. I have attatched a screenshot of what I believe you are trying to do. The Task has 2 channels in it, so I need to index off one of the channels and wire it into the active channels input of the Channel Property node. Then I can read information about that channel
    Attachments:
    channel_name.JPG ‏69 KB

  • How to get running Daqmx task handles

    HI,
    We are creating a TestStand module using CVI 8.5, in that module we have to close all the running Daqmx tasks, please provide help on how to get running Daqmx task handles. We could not find any API function which can return list of running Daqmx task handles so that we can close one by one.
    Thanks in advance for the help

    I just had a similar issue.  Stumbled on this forum in the hopes of getting an answer and found no reply to the original message.  I think this is what we are both looking for DAQmxGetSysTasks.  
    I havent used it yet.  Still in the excited I found something stage.

  • Getting AcceesViol​ationExcep​tion from NationalIn​struments.​DAQmx.Task​.Unregiste​rAsyncWait​Handle

    Hi,
    I'm using my own .net application that communicates with NationalInstruments.DaqMx.dll (version 9.7) in order to activate NiDaq in the following configuration:
    PXI -1033 chassis with two slots of PXI-6284, measuring differential voltage. This application was already running for some months and was tested under high performance - high sampling rate and long hours, with no problems so far. Recently we were trying a new use case - running short sessions (60 mins each) of measurements in sampling rate = 100 and samples per channel =100. after few iterations we keep getting access violation exception:
    Exception Info: System.AccessViolationException
    Stack:
       at NationalInstruments.DAQmx.Task.UnregisterAsyncWait​Handle(System.Threading.WaitHandle)
       at NationalInstruments.DAQmx.Internal.DaqAsyncResult.​AsyncOpDone()
       at NationalInstruments.DAQmx.Internal.AnalogMultiChan​nelMemoryOptimizedMultiSampleReadAsyncResult.WorkI​tem(System.Object)
       at System.Threading.QueueUserWorkItemCallback.WaitCal​lback_Context(System.Object)
       at System.Threading.ExecutionContext.RunInternal(Syst​em.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
       at System.Threading.ExecutionContext.Run(System.Threa​ding.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
       at System.Threading.QueueUserWorkItemCallback.System.​Threading.IThreadPoolWorkItem.ExecuteWorkItem()
       at System.Threading.ThreadPoolWorkQueue.Dispatch()
       at System.Threading._ThreadPoolWaitCallback.PerformWa​itCallback()
    Keeping the sampling rate as 100, but setting samples per channel to 1000 seems to solve this problem.
    Can someone explain me what is the cause of this exception?
    Thanks,
    Hadas
    Solved!
    Go to Solution.

    Thanks Mike,
    I attached the relevant code pieces. Generally, it is based on the example on NI-DAQ\Examples\DotNET4.0\Synchronization\Multi-De​vice\AIContAcquisition\cs.
    It has 4 classes:
    SyncTask - an abstract class that represents one task
    NiSyncTask - a derived class that does the actual access to DAQmx API
    TaskManager - an abstract class that manages several SyncTasks
    NiTaskManager - a derived class that manages NiSyncTasks 
    It's quite complicated, but I hope it will be helpful.
    Regards,
    Hadas
    Attachments:
    SynTask.zip ‏9 KB

  • Full information about DAQmx Task Name - How get?

    Labview 7.1 (information required for solve problem)
    I put in my application a DAQmx Task Name for fast configuration but i want put all information about task in a txt or spreadsheet file. But in Labview 7.1 haven't VIs like (http://zone.ni.com/devzone/cda/tut/p/id/3079):
    - DAQmx Info Query
    - General DAQmx channel Info
    - General DAQmx TEDS Info
    I'm using Analog Input (Voltage and Accelerometers) with several configurations and I need register all data of configuration to re-execute in the future or know about how acquisition data were gotten.
    I think that solve is in property nodes(DAQmx Task, DAQmx Channel, DAQmx Timing), but I believe will be hard work to make. Somebody has this working?
    Leonardo de S. Cavadas
    Maintenance Engineer and Inspection - Bureau Veritas do Brasil
    Engineer Metallurgist with emphasis in Advanced Materials
    Technologist in Computer Science

    Sorry about that, I haven't checked if they were made only for LV 8 and later. Attached is a zip file with all the VIs converted to the version 7.1.
    Some of them were not successfully converted and are presenting fatal errors when opening, probably because they have something not available in 7.1. But I'm sending you anyways, because the three VIs you mentioned in your first post that you wanted, are working fine in LabVIEW 7.1.
    - DAQmx Info Query
    - General DAQmx channel Info
    - General DAQmx TEDS Info
    Please let me know if this is of any help for you or if I can do anything else in this case.
    Best Regards
    Andre Pereira
    Attachments:
    DAQmxTaskInfoQuery.zip ‏586 KB

  • Would you Open and Close DAQmx tasks within a function or Globally

    Hi Guys,
    This should start something.
    The subject is DAQmx Tasks.
    If you were writing a function that is called many times, say MeasureVolts (double *Value) to obtain a reading from an Analogue Input Channel.
    Would you.
    1. open and start the task inside the function, do the measurement and then close the task inside the same function.
    or
    2. open the task globally and later do the measurement inside the function using the global task then close the task only when the application is closed.
    I am mostly concerned with the overhead of task generation and closing, what do you guys and girls out there do?? and what is the general opinion?
    I would appreciate your views.
    Regards
    Paul.

    I would definitely NOT keep configuring and clearing (I think that's what you mean by open and close) the same task over and over.  I would configure once, read many times in my main app, then stop & clear once.
    I typically like to package such data acq into an "Action Engine" that keeps track of its own DAQmx task id so I don't need to sling that task id wire around into multiple parallel loops / vi's.  Attached is a very stripped-down example for Digital Input. 
    I would typically do more with error testing and would make the "Action" enum into a typedef custom control, but this gives you the basic idea.  The action engine approach works very nicely when there's a small # of different kinds of input parameters and output info needed to support all the necessary action cases.   When you start needing a large number of differnent kinds of inputs and outputs to support the desired actions, then you start having difficulty with (1) having enough terminals to wire and (2) remembering which inputs and outputs are meaningful for which actions.
    -Kevin P.
    Attachments:
    DI Action Engine.vi ‏75 KB

  • How to Measure Frequency to RPM NI-DAQmx Tasks

    Hello,
    I am trying to measure frequency using NI DAQmx task and then convert this to an RPM if at all possible.
    I have the following hardware options at my disposal.
    I have SCXI 1126 Module along with a SCXI 1327 terminal, as well as a PXI 6289 Multifunction DAQ.
    I have wired in a mag sensor to ai7 on my 1126 and when I pass a metallic object I get a amplitude of 6  - 8  so I am able to read the mag sensor.
    What I am trying to do is to somehow convert this analog measurement into a RPM while only utilizing the NI DAQmx task.
    Any help would be appreciated.
    Tim
    Solved!
    Go to Solution.
    Attachments:
    Freq Set Up.jpg ‏2993 KB

    So I would select new in "Custom Scaling"
    Then would I select linear?
    Your calculations are simple but I am unsure if this would give me the desired result.  From my attachment I am seeing an input amplitude of 6 Hz for each pulse.  What I mean by this is that every time I bring a ferrous object near my mag pick up I get a pulse, this is what I was trying to illustrate in the attachment.  The analog pulse comes in a 6 Hz so I would simply multiple this pulse by 60 (assuming I get one pulse per rotation) to get RPM?
    How would this make sense if I only input one pulse for a long duration of time? 
    I have notice the amplitude of the pulse input increases with increased pulse frequency.  Does this mean the lowest RPM I can record is 360 RPM?  
    Tim

  • Is it possible to maintain the last AO value after the DAQmx task is done on device DAQ USB-6341 ?

    Hi all,
    I use the device DAQ USB-6341 to generate the desired voltage waveform by the "finite samples" sample mode.
    I notice that the channel resets to zero volts after the DAQmx task is done and the DAQ USB-6341 does not have 
    the property AO.idleOutputBehavior to select "Maintain Existing Value".
    How can I maintain the last AO value after the DAQmx task is done on device DAQ USB-6341 ?
    Thanks.
    Godel

    How many computers do you have in the network?
    What is the IP address and default gateway number on your computer?
    In order to connect to the wireless network, WVC80N should get valid IP address from the access point.
    If the access point has capacity to assign a private IP address to the computers and devices then I think you can use WVC80N.

  • PXI - DAQmx tasks will not export to MAX 5.4

    I am in the process of upgrading a PXI 1050 with an 8176 to an MXI bridge. The latest headache is that the CVI program had several DAQmx (tasks) defined in MAX 3.1.1 which will not export to MAX 5.4. I have been posting these additional questions on my original thread MXI not visible in MAX. I have many tasks for installed PXI cards. I was trying to make simple tasks just defining these cards to change the errors I receive in CVI. I do not have the option to define a task for some of these cards like the 4070 DMM. I did not generate the original CVI code. I am not sure what is defined the DAQmx. Can someone provide some insight ? I have viewed the suggested videos and white paper links. They were instructive but of little help.

    Unfortunately; no updates without dollars. While we all work for the same company, we must contract work between departments. There was no defect with the software as delivered. Old age crept in to the hardware. Any upgraded hardware, it turns out,  requires updating of the software. The unit had operated reasonably well, until a couple years ago. An unfortunate selection of network security software caused massive headaches. The software chosen assumed a more advanced level of hardware. Mandatory installation on all network computers rendered these controller inoperable. Our local IT guys shaved down the install to minimal components but the controller lost all available ram to this software, NI-MAX requires 20 minutes to build it's database on reboot. The computer controllers struggle to function. They periodically get lost and require a reboot, causing 30 minutes or more to restart. This is driving a replacement. We decided that it would be more cost effective to move to a standard computer interface. With the MXI, we could have a much more friendly and versatile interface. The upgrade is with a different "color" of corporate money. There isn't enough funding to contract a software upgrade. It is feasible to complete the upgrade in house, once we can identify the players and their function. Second we need the necessary time and access to the equipment. I do not have the ability to expend too many extra hours at work. So it takes time. I have been able to piece together the following. In the development stage back in 2004 - 2005, the developers used both Traditional DAQ and DAQmx. They build tasks for the SCXI in CVI. They have toolboxes making calls to Traditional DAQ. Also at some point in time they must have used the option in 3.1.1 to Convert Traditional NI-DAQ(Legacy)Configuration to NI-DAQmx, which built all the extra DAQmx devices we see in the device tree in the MAX 3.1.1. So beyound the errors there appears to be a few red herrings, just for fun. So there is no tasks to convert from 3.1.1, everything is contained in the CVI code. I have to find a way to use the CVI debugger to lead me to the nested, buried code causing the errors, and simply correct them. Just for another layer of complexity, they are probably logic errors, not syntax errors, or updated code errors where the legacy code no longer functions with the updated drivers. Or, hey, it could be the beta version of NI-DAQ, because it is the only one working with Windows 7 (32).

  • -200428 - Modifying a channel in a predefined DAQmx task

    I was pretty sure I had done this before, but maybe not.  I have a predefined task setup in MAX spanning 3 different analog input modules on a cDAQ chasssis.
    I'm attempting to modify the thermocouple type on one of the TC channels based on configuration setup data.  So I have the task selected as a constant and feed it into a DAQmx Task node to get the Channel List.  I can see the channel list just fine and all the channels are present there, but when I attempt to break the thermocouple channel out of the array and feed it into a DAQmx Channel node, I get an Error -200428, that the value must refer to a valid task or valid virtual channels.
    Any clues?
    Solved!
    Go to Solution.

    Hey Mike,
    Can you please try it like illustrated in the attached jpg.
    Christian
    Attachments:
    hint.jpg ‏36 KB

  • Examples for good programming practice with multiple DAQmx tasks

    I'm writing a program to continuously log data from 8 counters, 8 encoders, and 8 voltages. The proof of concept VI with a single counter was simple and elegant, but scaling up to all signals resulted in a wiring mess. I've been working through the Labview Core courses, and am currently on Core 3. I still haven't come across a discussion on how to work with multiple DAQmx tasks without making a mess of the block diagram. Can anyone point me in the right direction?
    Also, say I have a state machine that has a configure, idle, and logging states. I need to set the initial values of the encoders during configuration, and keep up with their changes while in the idle state so I have appropriate starting values when entering the logging state. Can anyone point to an example that shows how this might be accomplished?
    Thanks

    I'm very familiar with AE's/Functional Globals - but I have struggled in the past with handling multiple DAQmx tasks - particularly when you're using multiple devices and using different types of measurements which require seperate tasks/handling (e.g. such as thermocouples which require extra compensation).
    I'm not even sure I know whare the requirements are for needing multiple tasks - I know you can need multiple tasks for a single device if the type of measurement is different but can you share an Analogue Input task amongst multiple devices?
    I think in hindsight (and without too much thought now) it looks like a good case for Object Oriented LabVIEW - with a base DAQmx class (initialise, configure, start, acquire, stop, close etc.) and then child classes for each type of measurement (with one task associated with each - and private data unique to that specific class). You then hold an array of objects (one for each task) and iterate through each one with dynamic despatch to get the data.
    I don't know your particular experience level of using LabVIEW (and as such, OO may not be appropriate) - but as a wider discussion of 'best practice' it seems like an appropriate method I would use going forward.
    Certified LabVIEW Architect, Certified TestStand Developer
    NI Days (and A&DF): 2010, 2011, 2013, 2014
    NI Week: 2012, 2014
    Knowledgeable in all things Giant Tetris and WebSockets

  • Extract single channel from DAQmx Task

    Hello,
    I have created a DAQmx output task, which contains two channels.  Is it possible to extract individual virtual channels from the task to be processed by two parallel processes?  I have tried bringing out the Channels Property using a Task Property Node, but I then get the error that the channel is not part of an active task (see attached snippet)
    Could anyone advise on a better approach, or how to acheive this functionality - if it is possible?
    Regards
    Dave
    Solved!
    Go to Solution.
    Attachments:
    split out channels from DAQmx task.png ‏34 KB

    Sorry, that VI does not make much sense. You have to use a single DAQmx Write for both channels and for 1 Sample mode, you simply have to build an array of the signals as shown below.
    Attachments:
    two channel write.png ‏12 KB

  • DAQmx tasks

    Is it possible to run multiple DAQmx tasks on a single device at the same time? On a PXI-4204, I need to do a 1 point sample on ai0 every 100ms or so. The timing is not critical on this, so right now I am simply doing a 1 channel 1 point DAQmx AI task every 100ms in a loop. While this loop is running continuously, i need to randomly sample 1000 points at 1000 Hz on ai1 on the same card. When I try to start a second task after either of the two are first running, I get an error.
    Is there a way of doign this? These two tasks need to be independent of eachother, but sometimes must run at the same time. This is a simplified version of what my application requires, but if there is a way to do this I can figure out the rest.
    I am not too familiar with DAQmx and the 4204 yet, perhaps I am going about this the wrong way. Any input will be much appreciated.

    Hello RedRider. Thank you for contacting National Instruments. You cannot do more than one analog input task at a time. There aren't enough resources on the board to do this, you will have to do them one at a time. You can incorporate more than one analog input into a task, but this won't work with your situation. If you would like to make a product suggestion to do this in the future, click Product Suggestion. Hope this helps. Have a great day!
    Marni S.
    National Instruments

  • Display all DAQmx Task Names in Listbox

    I have a DAQmx Task Name control on my VI that allows the user to select from a list of existing Tasks created in MAX.
    I would prefer this list of "available tasks" to be displayed (and eventually have one task selected) using a listbox.
    For the life of me I can't figure out how to get the DAQmx Tasks into a listbox.
    Anyone have any advice?
    Solved!
    Go to Solution.

    Where are you getting the vaiants from?  It should be an array of tasks (a DAQmx task is a data type).  Just wire that array straight into the ItemNames propty for your listbox.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines
    Attachments:
    DAQmx Tasks to Listbox.png ‏13 KB

  • Storing DAQmx Task in a Functional Global variable

    Happy New Year to everyone!
    I got a nice little question hoping some of you might be able to help me....
    After initializing an starting a DAQmx task (V7.5), I wanted to store the task out reference in a functional global variable, but it seems, it didn't work.
    Everytime I tried to call a DAQmx VI with the opened reference, I get an error, the task would not be existing....
    I already made a workaround, so everything works fine. I'm just curious what I made wrong....
    Thanks in advance!
    Cheers
    Oli
    Programming languages don't create bad code, programmers create bad code....

    Helo Oli,
    Normally, you should not have a problem storing a task reference in a variable. However, the vi that created the task has to stay in memory for it to work. Closing the vi will result in the destruction of all created hadles -
    that is why your reference might be regarded invalid if you use it in
    another vi.
    That is why I can just assume that you are closing the VI that created the task before you are using the handle somewhere else. You can use variables to store the task ID, but as a workaround you have to keep the vi which reated the reference running.
    Hope this explains the behaviour.
    Regards
    Ingo Schumacher
    Systems Engineer Sound&VibrationNational Instruments Germany

Maybe you are looking for

  • In a fillable PDF form, can I have choose to have NO default choice in a drop down list?

    In a fillable PDF form, can I have choose to have NO default choice in a drop down list... so that a user is REQUIRED to make selection instead? I've set the question as "required", but the default answer makes this useless. I want to make sure peopl

  • Use blackberry as a hotspot with an ipad1

    can someone let me know if this is possible? I know how to use an iPhone, but my boss has a Blackberry Torch and an old iPad.

  • Oracle Package is a pl/sql block

    Hello , I am having a simple doubt on oracle package . A pl/sql block (executable section) must have a begin and end . But oracle package is having only the end part , so is it a pl/sql block or what ........................ Thanks

  • Using jce with java 1.3.1

    Hi, I use Java 1.3.1, jce 1.2.2 and eclipse. To include the packet added it with �Project/Properties/ Add External JARs� but when I compile the program I get the following errors: compile: [javac] Compiling 10 source files to D:\MyTemp\ZFProjectView\

  • ITunes and Keyboard backilght

    A bizarre behaviour. Hitting the spacebar to stop iTunes playing turn off the keyboard backlight... iTunes 9.0.2 (25) Now what?