LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Understanding DAQmx Functions

Hi , 

 

I have a few questions regarding the DAQmx Library in CVI.

 

1.While working with DAQ Devices I'm opening a Task and a channel to some device For example AO1.

 

I'm setting it to work with an external hardware trigger and defining all the needed parameters , starting the task doing the analog output and stopping the task.

 

so far so good , but if I want to repeat the same task without setting all the parameters again how can I do that ? Does the device remember it's configuration ?

 

the thing I need is to make a task that will repeat it self for days with out setting parameters because it takes time from each test,  time I don't have.

 

2.NI Function time cycle , is there any document that show how much time it takes for each function ?

 

3.  DAQmxErrChk (DAQmxCreateAOVoltageChan(gAOtaskHandle,AOchan,"",AOmin,AOmax,DAQmx_Val_Volts,NULL));

 

the values for AOmin & AOmax : if I'm setting it to -10 : + 10 , is it possible to change it with out creating a new channel ?

-----------------------------------------
Kobi Kalif
Software Engineer

0 Kudos
Message 1 of 5
(3,371 Views)

As per your Q1, provided you do not clear the tast you can start and stop it many times. I have used this method for digital output: I suppose it is the same for analog output.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
Message 2 of 5
(3,367 Views)

Hi Roberto , 

 

Iv'e tried it , it works fine.

 

Any idea about my other questions ?

-----------------------------------------
Kobi Kalif
Software Engineer

0 Kudos
Message 3 of 5
(3,361 Views)

While I have no idea about your second question, I suppose you can use DAQmxSetChanAttribute with DAQmx_AI_Max and DAQmx_AI_Min attributes respectively. I have no DAQ device at present to make a real test and see if changing these attributes with the task started raises any error or actually does not changes settings at all (that's why I didn't post this before), but you can try it in minutes.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 4 of 5
(3,358 Views)

You right it's work fine , i didn't knew if it's ok to change this val while running but it's ok.

 

As to Q2 i'll test is myself with the PC Clock or the timer.

 

Thank you.

-----------------------------------------
Kobi Kalif
Software Engineer

0 Kudos
Message 5 of 5
(3,350 Views)