From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Counter/Timer

cancel
Showing results for 
Search instead for 
Did you mean: 

What is error 50103? at DAQmx START task?

Solved!
Go to solution

Hi,

I am using cDAQ 9174 with NI 9401 to measure encoder period.  I have two encoders, and learned that I need to have  a separate task for each.  Initially, I got an error telling me that the task was not reserved, so, I followed the forum board and added the DAQmx CONTROL TASK, set to RESERVE.  That eliminated the error, but, now I get a new error 50103, which provides very little detail about what the error actually is.  The attached is a snippet of the code, where you see there are three tasks, two counter tasks to measure encoder period, and one voltage measurement task, which I believe is unrelated to this error. 

 

Error 50103 occurred at DAQmx Control TAsk.vi:3.

 

Possible reasons: NI Platform  Services:  T/he specified resource is reserved.  the operation could not be completed as specified.

Taks Name: _unnamed Task <3E>

 

So, initially, it was telling to reserve the task, now it is telling me that the problem is the reserve.  Does anybody know what this error is about?  The attached code is connected to a WHILE loop that is intended to do a bunch of stuff with the period data after it is collected.

 

Thanks,

Dave

 

 

0 Kudos
Message 1 of 14
(7,818 Views)

dav2010,

 

What device are you using as a counter? The 9401 does not have any counters on it. Generally, two counter tasks on the same VI should not throw an error if they are set up correctly and utilizing separate counters. I will note though, that the "Resource Reserved" error and setting your DAQmx state task into "Reserved" are two very different things. The error you are now getting is associated with the SW trying to allocate two separate things to the HW on one section of the device. You can read more about this HERE.

 

In general, if you copy and paste THIS example twice on your block diagram, you shouldn't have an issue as long as you are referring to two different counters. Let me know what device you are using.

 

Best,

Jason M.
Applications Engineer
National Instruments
0 Kudos
Message 2 of 14
(7,799 Views)

Hi Jason,

The 9401 uses the counters that are built into the cDAQ 9174, so, those are the counters I am using.  The 9174 has 4 counters, and I am trying to use two of them.  I was able to make the 50103 error go away by applying the DAQ Control to the second counter only.  I will look at the example you offered and see if that helps me understand it any better.  I am still having trouble with the vi, not in terms of errors, but, for some reason, the WHILE loop is stopping after 1 execution....can't figure out what is stopping it.

Thanks,

Dave

0 Kudos
Message 3 of 14
(7,791 Views)
Solution
Accepted by topic author dav2010

Hi dav2010,

 

I modified the original example to work with the two counters on the 9174. This worked for me. Let me know if it works for you too.

 

Best,

Jason M.
Applications Engineer
National Instruments
Message 4 of 14
(7,783 Views)

Hi Jason,

Did you test this on real hardware or simulator only?


Thanks,

Dave

0 Kudos
Message 5 of 14
(7,762 Views)

dav2010,

 

I tested this on real HW, but didn't send a pulsetrain to the counters. What kind of issue are you seeing?

 

Best,

Jason M.
Applications Engineer
National Instruments
0 Kudos
Message 6 of 14
(7,758 Views)

Hi Jason,

I am a little confused.  If you look at the attached vi, there is no "Period Input Terminal" specified but, this one works without error. I was told that the "CREATE CHANNEL" vi should do that automatically, and the only thing that is required to select is the CTR0, CTR1, CTR2 etc. as shown in the attached vi.  Anyway, I am getting error 50103 with my VI, which uses the same basic architecture as the attached, except it has some other stuff in it too, like measuring voltage, some calculations etc....  With the attached vi, if you remove the DAQmx CONTROL TASK vi, (where the "reserve" is selected") then the vi will not work.  The CONTROL TASK is necessary for the 3 counters to all work in my vi.  I can't get your vi to work. should I be selecting MOD3 PFI1, MOD3 PFI5 etc for the input terminal?

 

Dave

0 Kudos
Message 7 of 14
(7,669 Views)
0 Kudos
Message 8 of 14
(7,668 Views)

Jason,

Here is my code, with all the computations removed.  It measures 3 periods and 2 voltages.  Why does it give me the error 50103?  I thought the "reserve" would do the trick.

Thanks,

Dave

0 Kudos
Message 9 of 14
(7,662 Views)

Hi Dave,

 

Concerning error -50103, you may take a look at this KnowledgeBase article. It outlines several common causes of the error and provides troubleshooting and solution steps to avoid the error in the future. 

 

Hopefully you find this helpful. 

Best Regards,

Thomas B.
National Instruments
Applications Engineer
Message 10 of 14
(7,654 Views)