Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 
Reply

NI-DAQmx Error -50103 "The Specified Resource is Reserved"

Solved!
Go to solution

NI-DAQmx Error -50103 "The Specified Resource is Reserved"

I'm suddenly getting this error when I try to run my program. I've looked at the following page for guidance:

http://digital.ni.com/public.nsf/allkb/485201B647950BF886257537006CEB89

 

I've followed the steps for case 1 (resetting the traditional DAQ driver), but I'm still getting the error. All the other cases involve problems with the program itself, and this can't be my cause because my program was running fine when I left it before the holidays! Does anyone know if there's anything else not involving my program that could be causing this error?

 

Thanks!

Christina

0 Kudos
Message 1 of 6
(2,420 Views)

Re: NI-DAQmx Error -50103 "The Specified Resource is Reserved"

Hi Christina,

 

this error usually occurs when you run the task from one place, and you run the same kind of task on the same device from other place.

 

For example, you are running AI measurement in MAX, and you try to run your application with AI. To, you run one DAQ Assistant in one part of your code, and somewhere else you call other DAQ Assistant which calls the same kind of task on the same device.

 

In your case, if you didn't change your program, close any other application accessign the DAQ board - especially measurement in MAX.

 

 

regards,

stefo

Certified-LabVIEW-Developer_rgb.jpg

0 Kudos
Message 2 of 6
(2,411 Views)

Re: NI-DAQmx Error -50103 "The Specified Resource is Reserved"

I can't see anywhere else where the device is being used. Let me provide some more details now that I've been messing around with it this afternoon. I'm sending signals to two analog channels in a for loop. If the first iteration sends a signal to both channels, they work fine, but if I only send a signal to one of the two channels on the next iteration I get the error. Similarly, if the first iteration sends a signal to channel 0 and not channel 1 (or vice versa) this works fine, but if I try to send a signal to the unused channel in the next iteration I get the error. I know this sounds like a problem with not properly starting or clearing the DAQmx, but I swear this loop has worked fine for months! I've attached the code for reference, even though it's unchanged from when it worked...

0 Kudos
Message 3 of 6
(2,404 Views)
Solution
Accepted by topic author Aurora8283
08-27-2015 04:09 PM

Re: NI-DAQmx Error -50103 "The Specified Resource is Reserved"

At glance I don't see anything in your program. I guess some other program might be running.

 

However, I would definitely create and clear tasks just once. At the beginning and at the end - this could theoretically help you. I would also suggest you to split your big for loop into 2 loops.

 

btw, which task throws you the error?

Certified-LabVIEW-Developer_rgb.jpg

Message 4 of 6
(2,380 Views)

Re: NI-DAQmx Error -50103 "The Specified Resource is Reserved"

When I changed the program such that I only create and clear the task once I'm miraculously no longer getting the error! I have no idea why my program worked before and only now required this change, but I'm just happy that it's working again :-) Thanks so much for your help!

0 Kudos
Message 5 of 6
(2,372 Views)

Re: NI-DAQmx Error -50103 "The Specified Resource is Reserved"

hm, it seems that task wasn't cleared properly. This can happen sometimes, though it shouldn't. In general it is good idea to keep opening and closing references as rarely as possible. Beside you eliminate some potentional issues, rour code might run much faster.

 

i'm glad it works,

stefo

Certified-LabVIEW-Developer_rgb.jpg

0 Kudos
Message 6 of 6
(2,368 Views)