Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

Custom scale (for multiple channels to one single post-scaled value)

Hi,
I am using a NI PC6225 with the latest NI-DAQmx drivers in Visual C#. Now after my programm is almost completed I want to implement scaling and I've found the possiblity to use Custom Scaling. Is there also a possibility to scale multiple channels to one single scaled post-scaled value?
Another Question is: how do I get timing Data from my DAQ-Card. I know there is a counter on-board, but what does it count, and how do I convert this data to seconds or even DateTime?
Thanks so far
lunarfur
0 Kudos
Message 1 of 3
(2,977 Views)
Dear Lunarfur

I'm not sure whether I get your question right, so I'll try to answer
twofold:

1. You can't apply arithmetic operations on physical channels, so
anything like Ch0*Ch3+Ch2 doesn't work. Instead, if you want to
combine the data from multiple channels into one, you have to take the
channels' array data and reckon them up (in software).

2. You can adapt the custom scaling for multiple channels in a task at
run-time (and can of course scale them with regards to one data point
you've acquired before), but for the new scaling to apply you'll have
to stop and restart the task. It'd be more appropriate to scale the
channels' data by just doing some maths ...

Regarding you timing question: If you acquire with function ReadWaveform
you get a timestamp when the measurement reads the first data sample;
for all subsequent samples you can calculate the time according to that
timestamp and the sample rate.
0 Kudos
Message 2 of 3
(2,941 Views)
Thank you for your answers, although combining several channels to one single output could only be done by some math. But anyway I haven't regarded the possibility to collect data as waveforms. I will tryout this option.
0 Kudos
Message 3 of 3
(2,905 Views)