Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Where are nidaqmx low level functions?

After almost 10 years developing hardware and software at www.omnimetra.com.br using NI board 6023E with NiDaq legacy and Delphi, we are very dissatisfied with the "new" Niaqmx imposition (to use the 6220 board) which does not offers (officially) the same features as the legacy does.
In fact, the issue is very simple: where are the low level functions in Nidaqmx (as the legacy had) ?????
To make good software and SPECIFIC applications they are a must.
Obviously, such low level functions still exist, but they are NOT documented (at least, on the official documentation we get in NI CDs for nidaqmx).
 
For example, a simple byte output like DIG_Out_Prt() very useful in some circunstances present in the Legacy, does not have equivalent in the mx where we always need to create and set a cumbersome, heavy and slow task to write through a buffer, that obviously cannot work in some realtime severe circunstances.
 
Can someone tell me something about? Or should we at Omnimetra start looking for another aquisition board manufacturer (like Agilent)?
 
Thanks,
Lavio Pareschi
 
0 Kudos
Message 1 of 62
(6,266 Views)
Hi Lavio, good morning.
 
Sincerly i´ve never used NIDaq Legacy, but using NIDaqmx you can find the low level functions at Programming >> Measurement I/O >> Daqmx - Data Acquisition in functions palette (Block Diagram).
 
Regards,
 
Filipe Martarello
Applications Engineering
NI Brazil
0 Kudos
Message 2 of 62
(6,228 Views)
>  but using NIDaqmx you can find the low level functions at Programming >> Measurement I/O >> Daqmx - Data Acquisition in functions palette (Block Diagram).
 
I did not find it.
Where is it? In NI Developer Zone, Support, Solutions, Brazil site, documentation, knowledgebase, produtc manuals??
 
In Programming Fundamentals, there is no "measurement I/O".
Also, searching for "nidaqmx low level functions" in entire site, there is no return. Zero. Nothing relevant, except a message from other guy who also commented about the (absurd) lack of low level functions in the nidaqmx !
 
LMP
 
0 Kudos
Message 3 of 62
(6,224 Views)
Hi Lavio. 

What are the functions that you´re looking for?
You can see at the link below that there´s a way to do that but some functions was removed from the Legacy to the Daqmx. Those functions that i told you are located at the block diagram on LabVIEW in the same way posted before.
If you have any doubts, please, ask me again!
 
Link:
 
 
Regards,
 
Filipe Martarello
Application Engineering
NI Brazil
 
0 Kudos
Message 4 of 62
(6,216 Views)
Let me stick my $.02 in here. I have never used Delphi but occasionally use CVI so I'm a little familiar with the DAQmx and traditional DAQ functions. With the old DIG_OUT_PORT, you had to first use DIG_PRT_CONFIG. With DAQmx, you use DAQmxCreateTask, DAQmxCreateChannel, and DAQmxStartTask. Just like DIG_PRT_CONFIG, these need to be run only once. After this, you need only call one of the DAQmxWriteDigital functions. If you had an 8 bit port that you controlled with DIG_OUT_PORT, then the equivalent is DAQmxWriteDigitalU8. I don't think a buffer creation is required unless you use hardware timing.
0 Kudos
Message 5 of 62
(6,208 Views)
Thanks Mr. Dennis.
Yes, all those functions and changes were tested, to use the nidqmx.
The problem is the timing involved in using the "task" approach. Even if you just use the DAQmxWriteDigitalU8, it needs to start, write, wait the task is done and stop it. As I wrote, this approach does not work for real time serious applications with critical timings below 1 ms for a single write operation.
I wish I was wrong and missed some point on using those nidaqmx functions (that's the reason I wrote here, to get some insight and help), but until now I did not see how it can be used as easy and fast as using the old, simple (and good 🙂 Legacy low level functions, unless they do exist but are just not documented -- my bet, because NI guys, to make the worshiped LabView code... probably used low level functions NI did not documented for us, if we want to use other languages as CVI, C++ or even Delphi that give us much more freedom, power and not buying LabView stuff...:-(.
 
LMP
 
0 Kudos
Message 6 of 62
(6,198 Views)
> What are the functions that you´re looking for?
 
Read please the first message.
 
> Those functions that i told you are located at the block diagram on LabVIEW in the same way posted before.
 
Labview, Labview, Labview...
I am not talking about LabView, Mr.
Or are you telling us that NI now only supports LabView applications for its boards !?
 
LMP
 
0 Kudos
Message 7 of 62
(6,195 Views)
When I use tasks, I start them at the beginning when the program first loads and do not close them until the program exits. When you used the traditional DAQ function, did you call DIG_PRT_CONFIG each time or just the DIG_OUT_PORT? Yes, starting and stopping a task repeatedly does take quite a bit of time but I don't think that is the intended way to use DAQmx.
0 Kudos
Message 8 of 62
(6,193 Views)
Sorry, i miss this information.
 
Filipe Silva
0 Kudos
Message 9 of 62
(6,186 Views)

> Yes, starting and stopping a task repeatedly does take quite a bit of time but I don't think that is the intended way to use DAQmx.

Yes, but that's the problem, because I was not able to make them work (the task functions) for digital output if I do not use the autostart parameter = true in the digitalwriteU8() function or do not use write (no autostart) + start + stop in the sequence. In both cases, the timing is not good enough. In fact, in the WriteDigitalU8() you also set the number of bytes and the buffer address to write, and to write 1 byte, 100 or 1000 makes not much diference. It takes more than 10 ms in a 2GHz machine if you use cfgClkTiming() to set a output clock generation and 0.7 ms if not to output a 100 bytes block.

A curious point is that if you do not use cfgClkTiming(), do not use waitTaskDone() and use autostart, then it takes much less time.
Also, another thing I did not understand, is that the cfgClkTiming seems not be obeyed. If I set a 1 KHz clock and send 1000 bytes, it does not take 1 second... or 1 byte each 1 ms as I would expect from the documentation, but also between 10 and 15 ms.

I really would like to see more actual working EXAMPLES in the documentation for using other languages that not LabView, to check if I missed something after reading 1001 times that horrible documentation without a single example.

Thanks, LMP

 

 

0 Kudos
Message 10 of 62
(6,185 Views)