02-20-2007 12:50 AM
02-20-2007 06:52 PM
02-21-2007 01:42 AM - edited 02-21-2007 01:42 AM
Message Edited by pkowalak on 02-21-2007 01:48 AM
02-21-2007 07:43 AM
While you can't get timing information bundled as part of a waveform datatype, you definitely CAN timestamp all the encoder's rising edges. You would configure your counter for either Frequency or Period measurement. In these modes, the DAQmx Timing vi should be set for "Implicit (Counter)".
Once you receive your array of frequencies or periods, you can pretty easily sum them to create an array of timestamps. The remaining difficulty is to sync the analog and counter measurements to start at the same t=0. I'm not sure whether you can sync the two types of measurements with express vi's because I never use express vi's.
I'm out of time now, but the kinds of terms you might search on to learn more include "frequency measurement", "Arm Start Trigger", "synchronize counter".
-Kevin P.
02-21-2007 12:30 PM
02-21-2007 04:56 PM
can you describe briefly what does mean: "In these modes, the DAQmx Timing vi should be set for "Implicit (Counter)".?
I use for my aplication only express VIs, can I use some other tool too?
I use the DAQmx function palette to define data acq tasks programmatically. If you choose "Find Examples..." from the Help menu, and examine the DAQmx functions that are called to implement some of the simple examples, that will help you get started. Quite a lot of us are largely self-taught and started just that way.
The "problem" with express vi's is that while some kinds of stuff is really easy to do, other stuff is just plain impossible. There isn't any way to bridge the gap from the easy to the impossible. However, if you program with the DAQmx function palette, you can work your way along from fairly simple tasks to very complex ones at your own pace.
-Kevin P.
02-21-2007 11:50 PM
OK, looks that I simply have to keep on learning of new way of LabView programming. But Just a one more question. In prewious message was mentioned that I can not get timing information from hardware. But if I will use DAQmx Timing vi, it will give me accurate time stamp? I affraid that there can be some kind of distortion due to software delays for example.
regards
02-22-2007 07:39 AM
Short answer: your timestamps can be measured with sub-microsecond hardware-level precision regardless of software delays.
Expanded notes:
1. DAQmx Timing is one of several DAQmx functions used to configure, start, read, stop, and clear data acq tasks. It is used whenever you want to collect multiple samples of any signal. When you *do* use it, you will define a hardware signal as a sampling clock which is why you will get good precision / accuracy.
2. The timestamps you want are something you will need to derive from your frequency measurements -- the board won't return matched pairs of freq and timestamp. However, the mathematics is pretty simple. Each sample interval is defined as 1/freq, and each frequency's "timestamp" is the cumulative sum of all those intervals. (Note: the very first measurement can be a special case, representing the time from when the task started until the 1st signal edge. This value will often be meaningless.)
-Kevin P.
03-15-2007 11:48 AM
03-15-2007 11:48 AM