10-10-2017 04:46 AM
Hi,
I have a big problem with LabView, and I'm totally a beginner on this soft, plus it's hard for me to understand english so I didn't manage to resolve my problem with things I found online.
So I'm using a CompactDaq-9138 with 4 cards : (9232, 9213, 9223 and 9203). And i'm on LabView 2012 (12.0). When I started my work The vi was already made for 3 cards and it work fine.
Now I need to use the 4 cards that I have. But when I try that I have an error : "- 200022 occured at DAQmx Start Task.vi : 4. Ressource requested by this task has already been reserved by a different task".
And I tried with only 3 cards, no matter which cards it was it worked, it's just when I have the 4 cards simultaneously. I always have this error on the "start.vi" of the fourth channel. I join my VI to this message, so it always occur at the "start vi" after the "start digital edge".
I already read some similar topics on the forum, about the clock of channels, things like that... But I'm really a beginner on LabView it's really hard for me to understand. (Plus I am french and the technical explanation in english on a soft that you don't know is complicated ^^").
So if someone know why I have this error and can explain it to me it would be really nice, because I've tried multiple things and don't know what to do now...
Thanks a lot
10-10-2017 06:50 AM
Your problem is that the cDAQ-9138 only has 3 analog sample clocks. This means you can only have 3 AI tasks. What you need to do is put all of your analog input channels into a single task. This will greatly simplify your code and make it more scalable.
10-10-2017 07:19 AM
Thanks for your fast answer.
Ok too bad it can't have 4 tasks ^^".
Would it be possible that you explain to me how I can have 1 task for everything? I don't know if you opened the vi but I need all the acquisition to start at the same time.
So I don't know how to have everything start together with one analog sample clock, can you detail it to me a little or make a really simplified vi of that? I'm sorry again I barely understand what is a "task" it's the first time I use LabView and I'm alone on it without formation so I have trouble to understand how it work ^^"
10-10-2017
10:26 AM
- last edited on
12-17-2024
06:53 PM
by
Content Cleaner
Krafter37 wrote: I barely understand what is a "task" it's the first time I use LabView and I'm alone on it without formation so I have trouble to understand how it work ^^"
In that case, start here:
Learn 10 Functions in NI-DAQmx and Handle 80 Percent of Your Data Acquisition Applications
10-11-2017
01:49 AM
- last edited on
12-17-2024
06:54 PM
by
Content Cleaner
Hello,
When you read the documents given by crossrulz, you can find an exemple with multiple tasks:
NI-DAQmx: Creating an Analog Input Task with Multiple Measurement Types in LabVIEW
https://forums.ni.com/t5/Example-Code/NI-DAQmx-Creating-an-Analog-Input-Task-with-Multiple-Measureme...
Have a good day
Eloise
NI France
10-11-2017 03:50 AM
Hello,
Thanks for the documentation and thanks Eloise for the focus on that part that helped me a lot ^^
Just something that bother me : with the example all the channels have the same rate of acquisition if I understand right?
For me I need to have a different acquisition rate (again sorry for my english) for each channel (temperature, current, voltage, ...). Is it possible if I use only one analog sample clocks to have 4 differents rates?
Good day to you too
10-11-2017
04:00 AM
- last edited on
12-17-2024
06:54 PM
by
Content Cleaner
Hi,
NI cDAQ-9138 chassis provide three timing engines for analog input. So you can't create more than 3 tasks with different timing :
How Many Different Tasks Can Concurrently Run on a CompactDAQ Chassis Gen II?
https://www.ni.com/en/support/documentation/supplemental/18/number-of-concurrent-tasks-on-a-compactd...
Eloise
NI France