Daqmx timed task - Help!

Hello

Looking for the online help on a task daqmx timed.

I am trying to run 2 fans using tasks of acquiring data MX for some time. The sequence is the following:

1. start the FAN 1 and run for 2 minutes.

2 after the 2 minutes time, STOP FAN 1 and FAN 2.

3. operate the FAN 2 for 3 minutes.

I need to help, incorporating a timer in the task.

I would really appreciate if the community would throw an overview of this. (Maybe a quick picture of the code?)

Thank you

RP.


Tags: NI Software

Similar Questions

  • Do you need 'DAQmx start task' vi read from a device NI DAQ (NI 9205)?

    I have a NI 9205, which I use to get a waveform data. To get started quickly, I used the wizard DAQ Vi. The code below (FIGURE 1) is the acquisition of data help VI looked like when I convert LabVIEW code and made some minor adjustments.

    When I looked online to see how to get hardware DAQ data, many sources use the task start DAQmx in figure 2.

    DAQmx start using VI makes another?  Materials using DAQ assist in loop gives you a lack of performance?    If so, figure a will have a lack of performance too as it is basically the DAQ help code?

    FIGURE 1

    Hello sticyfinger,

    Help for the Start Task function:

    "If you do not use this VI, a measurement task starts automatically when execution of the reading DAQmx VI. Automatic start of theDAQmx VI entry write determines if a build task starts automatically when the execution of the writing DAQmx VI.

    If you do not use the DAQmx start task VI and VI task DAQmx stop when you use DAQmx Read VI or VI to write DAQmx several times, as in a loop, the task starts and stops several times. Start and stop a task repeatedly reduce the performance of the application. »

    Hope that helps!

  • USB-6212: software problem timed task of analog input

    Hi all

    I have unexpected behavior using a USB-6212.

    The code example shows that when I run in sequence two analog DAQmx to task, material entry first a timed, the second software timed, it happens that the first readings of data are all wrong and have the same value for all channels.

    The labour code is the following:

       GetCtrlVal(panelHandle, PANEL_HW, &Switch); 
    
        if (Switch) {
    //
    // First Task: read 10 rows of values with hardware timing
    //
            DAQmxCreateTask("", &htAI);
            DAQmxCreateAIVoltageChan (htAI, MX_DEV_AI, "", DAQmx_Val_NRSE, -10.0, 10.0, DAQmx_Val_Volts, "");
            DAQmxCfgSampClkTiming(htAI,"", SAMPLE_RATE, DAQmx_Val_Rising, DAQmx_Val_ContSamps, 1000);
            DAQmxRegisterEveryNSamplesEvent (htAI, DAQmx_Val_Acquired_Into_Buffer, SAMPLE_RATE, 0, RefreshCB, NULL);
            DAQmxStartTask(htAI);
                Delay(1.0);
    
            DAQmxStopTask(htAI);
            DAQmxClearTask(htAI);
        }
    //
    // Second Task:read 10 rows of values with software timing
    //
        DAQmxCreateTask("", &htAI);
            DAQmxCreateAIVoltageChan(htAI, MX_DEV_AI, "", DAQmx_Val_NRSE, -10.0, 10.0, DAQmx_Val_Volts, "");
            DAQmxStartTask(htAI);
    
        for (i=1; i<=10; i++) {
            DAQmxReadAnalogF64(htAI, 1.0, 10.0, DAQmx_Val_GroupByChannel, AcqVoltRow, HW_AI_CHANNELS, &read, 0);
            SetTableCellRangeVals (panelHandle,PANEL_SOFT, MakeRect(i, 1, 1, HW_AI_CHANNELS), AcqVoltRow, VAL_ROW_MAJOR);
            Delay(0.1);
        }
        DAQmxStopTask(htAI);
        DAQmxClearTask(htAI);
    

    A picture is worth a thousand words: analog inputs have been connected to a network of resistance have known values.

    The upper table contains timed material acquisitions, the lower the software timed readings... as you can see it the first line is the set of values of 0.13, totally wrong

    If the task of timed acquisition of software runs without the earlier (in my demo, that this can be achieved by the switch at the top right), the readings are correct!

    Y at - it something I am doing wrong?

    I also tried to run the program on USB-6009, but it seems to work properly.

    [LabWindows/CVI 2010 SP1 - driver OR-DAQmx 9.4 - Windows 7 x 64]

    This problem was corrected by NOR-DAQmx 9.5

    324044 NOR USB-621 x task HAVE request returns incorrect data after erasing a task HAVE stamped

  • Daq stop task VI back to the State of the task was really forward the DAQmx Start Task or DAQmx writing?

    Hello

    I use DAQmx and DAQ Assistant and try to get the details on the following questions.

    1 does Daq stop task VI really return to the State of the task is in front the DAQmx Start Task or DAQmx writing? Digital Input taking as an example, I don't think that the status of the task means that input data because I tried and I can't really back to the entry level it was.

    Maybe more experienced people can help to share their expertise.

    2. the information in help indicates "virtual channels created with the function/VI DAQmx create Virtual Channel are called virtual channels the and cannot be used in the task." But I don't know what "in his work" means.

    3. could I get some guidelines or expertise on the Labview programmers when use virtual channels the and when, to the more global?

    Thank you!

    Best regards

    Allen

    If you create a channel of the task, or scale just usuing the screw to create or Assistant session wire io is the only way to pass the info autour.  It is not saved anywhere on the disc.  A channel of the task or the scale in a project can be used by anything in this project.  A channel of the task or the scale recorded in MAX can be used by anything on this machine.  Its an extended thing.

    And Yes, the DAQ Assistant fresh extra performance overhead and the poor than the DAQmx API.  Often, it won't have the impact of a little experiment.  Large applications should avoid the express Visa.

  • Error-50103 occurred at DAQmx start Task.vi:11

    Hello

    I use a nor-6008 to perform a thermal sector and I get the error "error-50103 occurred at DAQmx Start Task.vi:11 '. I have read other forums of discussion and it seems combe because I use the wizard DAQmx who don't properly resolve the resource when finsihed. I've dug further and saw that it is linked to an on-board clock synchronization problems. However, I can understand how to solve this problem.

    I thought that I create a loop that continuously monitors inputs and sometimes to interrogate the memory so I'm not kidding to the top of the clock. It's much harder to do than sounds. Can someone take a look at my code and give me some advice/suggestions to clean the DAQmx assistants.

    Thanks in advance

    Cole

    I finished by dividing my resource between the two input channels using a single assistant DAQ and dividing down the data rate and the number of samples. Works fine now.

    Big pain in the ass well.

  • Stand-alone application with LabView 7.0 get error cannot find DAQmx clear task.vi

    I tried to create a stand alone vi with the Build Application or shared Library (dll) in LabVeiw 7.0

    When I put it on another PC to test it I get the error "cannot find DAQmx clear task.vi.

    the other PC also has 7.0 and 8.1 DAQmx Labview.

    I think my problem is in the source tab, where you are supposed to add dynamic vi and support, I have search the forums and database of nor and have not found a solution.

    Hi LabTech09,

    When you run the executable file on the other computer, that's when you get this error?  You have the same exact versions of DAQmx and LabVIEW on both computers?  Is the dialog box allow you to navigate to the clear task.vi DAQmx?  If so, you can find these screws in C:\Program NIUninstaller Instruments\LabVIEW 7.0\vi.lib\DAQmx\configure\task.llb.  The executable runs on the development computer (the machine, it was compiled on)?

  • How to set DAQmx period task input terminal

    I have a measurement period counter as task created in VB6.0 using Measurement Studio 8.6 and NOR-DAQmx. Is it possible to configure the input (door) to be PFI0 instead of the default Terminal.

    Thanks, vecsol...

    The terminals of the meter are wired on certain pins on the DAQ card.  The door of the Terminal is not set for a 'default', the door of the meter is connected to a certain line of PFI - this cannot be changed.  See help NI - DAQmx Device terminals for more information on PFI line corresponds to what terminal of the meter.

  • more info on the DAQmx control task

    Today I came across an older post where I had some questions and Jeff· just Þ· Bohrer showed a good example, it's here:

    http://forums.NI.com/T5/LabVIEW/AES-single-element-queues-data-value-references/m-p/2978093/HIGHLIGH...

    I doesn't pay attention to the DAQmx task manages the part, but now some new questions of time came to my mind, I hope someone can give me some explanations...

    Usually, when I'm working with some hardware with DAQmx driver, I simply specify the channel, and I use the VI of virtual channel create for my work I want to use.

    Recently I read about benefits use MAX to previously create some global (?) of the tasks (for example a cDAQ with many modules and i/o channels) and using these tasks in a LabVIEW project. In this case I can just skip the 'Create Virtual Channel.vi', begins with the measurement with a "Start Task" DAQmx and stopping a VI 'stop the task', correct? However in the link above, the VI "Task of control" (next), first used with a parameter "commit" and during the closing of the measure, with a setting of "Cancel" (and no task to stop vi was used).

    I threw an eye using the Task.vi 'control', but the info it is not too detailed, where I can find a few more details, or maybe someone might highlight the use and benefits of this vi? Sounds a bit 'funny' aid, as for the parameter commit: "Programs the hardware as much as possible depending on the configuration of the task."

    So what is the difference between the use of the "task of control" in a code and do not use it (so when we use only the start and the stop task live)? Do we not the same behavior with the latter?

    Thanks in advance!

    Martins wrote:

    The overall task configured max subject: we conduct research, so I always just develop for our lab, we do not sell anything. However, I have some questions related to a task configured and saved to the MAX:

    • So I have a task created at MAX, I guess that this task will be usable only if I use it in a project of LV on the same PC? What if I need to move my application to another PC (but of course with the same modules cDAQ, etc., but perhaps under different numbers...)

    The task can also be used with a .exe. You can export MAX settings to a file (file, export...) .nce, and then import the settings to a new PC. If necessary you can tweek the numbers.

    • I would like to create an EXE from my code and don't run this EXE to our systems (not install). Y at - he tips that I should keep in mind when I create an executable from a project that contains a task of MAX?

    I can't think of something special. Personally, I prefer to load the name of the task from a configuration file, you can also use a control on the front panel to select the task.

    I have a feeling, when we need complete flexibility, the course of MAX isn't really practical, Yes? I want to say, if we want to for example programmatically recognize all our application materials and create tasks to ensure that all physical changes on the side of the PC in the future will not affect our code?

    I agree that you have as much flexibility, but for my applications most of the time MAX provides sufficient flexibility

    But this scenario could be documented for future users in the lab, I imagine, so what they have to do, is to recreate the overall task? What happens when we take the application as an exe on another PC and manually re-create the (I hope that quite the same) necessary global task with the same name that awaits the EXE? It works this way?

    Thanks for the very useful info!

    Edit: "Yes you can set a MAX task that includes several modules and channels so that they all have the same type of action."

    This is also a limitation compared to the creation of code depending on task, Yes? I mean, using the DAQmx 'Create Virtual Channel.vi', we can even combine for example analog inputs with for example in a cDAQ thermocouple hunts...

    No it is not a limitation, for thermocouple is entered analog. If you can combine them in LabVIEW, you can combine them in MAX.

    Edit2: I really miss other docs of type "real demonstration" of the NEITHER! I could imagine a sort of case study examples where different material handling OR would be explained... Of course we can hunt together pieces of mosaic, but a more compact image could help a lot for those who want to learn faster

    Ben64

  • How to measure the frequency of NOR-DAQmx RPM tasks

    Hello

    I'm trying to measure the frequency using the NI DAQmx task and then convert it to a RPM if possible.

    I have the following material available to me.

    I have a block SCXI-1327 terminal, as well as a 6289 PXI multifunction data acquisition Module SCXI 1126.

    I wired in a mag ai7 sensor on my 1126 and then of the passage of an object metal I get a range of 6-8, so I am able to read the mag sensor.

    What I'm trying to do is somehow convert this analog measurement a RPM using the NI DAQmx task only.

    Any help would be appreciated.

    Hi, smooth,

    Yes, you would select linear, then put in the result of this calculation of the slope.

    The Manual recommends a minimum frequency of at least 15 Hz for setting low range. This card is not really designed to measure the frequency for a single pulse over a long period of time.

    The number of LAPS down (assuming one pulse per turn) that we recommend that you measure with the 1126 is so 900 RPM. If you need measure low revs, and you cannot increase the number of impulses per turn, you could consider either read the signal as an analog waveform, or if it's a digital pulse, using a counter to basic task. In this way, you can use any method you want to handle the situation where there is only a single pulse in a long time.

  • Several DAQmx Timing screws - all seems to work, just a question

    I wrote a Labview program to interface with a cDAQ-9188 and everything seems to work very well. I used the DAQ Assistant to make the features of basic level and then convert them into DAQmx code and which went very well.

    When I created the code DAQmx a timing clock didn't appeared not so I added a vi DAQmx sample Timing (sample clock) in order to have control over the rates. I tested the software, including changing my recording speeds, and everything worked as expected. (see image).

    When I looked in the SubVi DAQmx I created, I saw that a synchronization clock was actually there (see image). It contained cable to it (sample, rate, samples per channel mode) but this content does not seem to affect what I have in the main VI. Heck, I don't even samples per channel wired on the main VI, I plugged it into my DAQmx Read in my all loop!

    If the Timing of the main VI is predominant in the Subvi calendar? Should I take the full schedule of the Subvi?

    Once again, everything seems to work as expected. I have more work to put into this and I fear that it will cause headaches in the future. Also, I want to be more informed about what I do!

    I have attached the VI and SubVIs as this seems to be the Protocol. They are under construction!

    Thanks for the help.

    If you open the VI schedule you will find that it contains just the DAQmx definition properties:

    Calling it the second time only replaces what you have done previously.  It would eliminate a redundancy to just call him once (you could delete the calendar from your Subvi or pass the parameter in the Subvi to configure it) but it isn't a problem to call it twice.

    Best regards

  • to run several DAQmx AO tasks at the same time

    Is there a reason any cannot perform several tasks DAQmx AO at the same time?

    It's a bunch of questions that you listed there. I strongly suggest that you spend some time reviewing the many tutorials available for acquisition of data here: http://www.ni.com/white-paper/5434/en. You will need to get a better understanding of the work equipment, and reading some of these articles will help you considerably.

  • Error-200022 occurred at DAQmx start Task.vi

    Hello

    I have peripheral cDAQ and 3 modules that nor-9234 connected.

    My program (see attachment) works correctly with only 2 modules, but does not work with 3 modules.

    With 3 modules I have this error: "error-200022 occurred at Task.vi DAQmx Start.»   "Possible reasons: resource requested by this task has already been reserved by another task."

    To solve this problem, please help me

    Thank you

    Now I understant the error. This is correct (see below)

  • Strange DAQmx Timing delay home error loop

    I have a digital dashboard introduced in a timed loop counter. Everything works fine until I have stop the loop and stop the task of data acquisition. Once I restart the loop that it fails with 'resource is reserved. My code is attached.

    Thank you

    I think the problem is that when you set up a timed loop to use DAQmx task as its source of the time, the timed loop is automatically set to start the task at the start of the loop. Here, you never seem to stop the task of counter before restarting the timed loop. For the second time that you run the loop timed, it tries to restart the task of Counter and sees that a task is already running with this resource (from the first timed loop run).

    If you use the function of the task to stop the task of counter after the timed loop, you should be able to restart things.

  • error-50103 occurred at DAQmx control Task.vi:6

    I'm new to LabVIEW. I'm using LabView 8.6 and one NEITHER cDAQ-9172. For practice, I'm doing a program that takes the temperature and pressure readings and graphs.

    I don't have the modules or sensors yet, so I started by simulating a RTD temperature measurement NI9217 and a NI9237 module for the measurement of pressure.

    I created 2 while loops that run in parallel. One with an assistant of data acquisition for the temperature and the other with an assistant of data acquisition for the pressure.

    Highlight run out, when I run the program, the signal is both while loops. The temperature seems to work ok and the data graphic. The pressure, however, only goes in once, and I get the error message: "error-50103 occurred at Task.vi:6 DAQmx control Possible reason (s): the specified resource is reserved." The operation could not be performed as indicated. »

    In addition, the stop button does work on my front. I have to use the button stop in the toolbar.

    Anyone has any advice on what I can do to fix this problem or any suggestions on the best ways to address the issue?

    Thank you.

    Search the forums for error 50103.  That will tell you everything you need to know about this error code.

    For more information on your questions, post your VI so we can see what might be wrong.

  • set up a placeholder or virtual DAQmx SCXI task?

    is it possible to implement a task DAQmx SCXI without having any SCXI hardware?  I don't have access to the material and I was wondering if I could create a "virtual task' for my SCXI program before gettting the material?

    Thank you!

    Yes.  Go to measure Automation Explorer.  Devices and Interfaces, do a right click, create new ones...  You can then select Virtual Instrument or NOR-DAQmx simulated device.

Maybe you are looking for

  • Tecra R940 - 1 6: Self Encrypting Drive - wiping technology - how to activate?

    Hello We recently bought a 6 with a SED - technology disk wipe the Tecra R940 - 1. We have difficulties to find any documentation on how we allow this technology.Allow us the user to the HARD drive and master passwords, but can not find any activatio

  • Is it possible to save emails in my TC?

    Hello Basically, the idea is to send to the group or by email to a specific to my TC folder. Say it must be identical to the movement of the location of the folder archived to the time Capsule so that the ability of this device can be used for that o

  • AutoComplete on structure member

    Don't know if this has been asked before, but my "AutoComplete" CVI 9.0 does not provide the members of the struct quick reference box when I put a picture of structures within another structure. To illustrate, add this code at the top of any C file

  • job cuts coming on the network of a macbook to print spooler

    Incoming jobs if displayed in the list of the work coil then disappears before printing. I'm using the latest drivers from HP, Epson. (4 computers and printers on the network. MacBook is the fifth computer. Apple said that, given that the work has ap

  • HP Officejet 6700 Premium: System 6700 Premium ink or printer failure

    Went for a month and when I get back, printer displays message-printer failure. System problem or printer ink. Turn on and turn it back on. If the problem persists, contact HP. Were doing 20 + times. Used PR without result.