NI Home > Community > NI Discussion Forums

LabVIEW

Showing results for 
Search instead for 
Do you mean 
Reply
Member
AustinConsultants
Posts: 64
0 Kudos

error 50103

Hello,


I keep getting the joyous Error 50103 after the start task, I cannot get the product to run at all now. I have reset the device and followed all the steps on the nI recommendation page. None of them unfortunately seem to solve the problem and MAX wont let me get data either, stating the same error.


Any ideas how to resolve?

 

Thanks 

Knight of NI
RavensFan
Posts: 16,018
0 Kudos

Re: error 50103

You have some process or program somewhere that has the DAQ device already in use.  Normally, it is multiple DAQ tasks in one program using the same card.  It could be one DAQ task while yoiu have MAX open at the same time.  Could be something else.

 

Close down everything and reopen and try again.  If that doesn't work.  Close everything, shut down and reboot.

Active Participant
JohnMc19
Posts: 218
0 Kudos

Re: error 50103

Hi Develop-inG,

From the code you posted I can see you have made a copy of the 'Dev1,a0:1' constant and have not wired it to anything, it could be a an idea to delete this.

Let us know if any of the steps you've taken have worked!

Regards,

John McLaughlin
Insides Sales Engineer Team Leader
National Instruments UK & Ireland
Member
CJHartshorne
Posts: 197
0 Kudos

Re: error 50103

Hi Develop-inG,

 

I have found a Knowledge Base article which relates to the problem you are seeing which you may or may not have already seen. I have linked this below for your convenience.

 

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

 

Having had a look at your code I would suggest that Case 2 seems like a potential cause of the problem since you are continually creating and starting your task in a loop. You should only need to create, configure and start your task once, then call the read function in the loop as needed.  For an example on how to best architect your DAQ application refer to the Cont Acq&Graph - Int Clk.vi example that is referred to in the linked KB.  To find the example, launch LabVIEW and go to Help»Find Examples.  Browse by task to Hardware Input and Output»DAQmx»Analog Measurements»Voltage.

 

I hope this helps.

 

Best Regards,

 

Christian Hartshorne

NIUK

Member
AustinConsultants
Posts: 64
0 Kudos

Re: error 50103

Hello,


Thank you for the messages. I have seen the articles and case two is indeed the reason why I got the error in the first place. What I am after was a solution to undo this error on the fly. Ie, when it turns up and creates that error that I can go into the error handling fg and put in some code to free up the resource and start the task again. If anyone knows if this is possible that would be ideal. This is on a long term logger so needs to be clever enough to solve its own problems without human intervention.

 

The DAQ constants are things I wired in while trying to solve the problem and see if the other tasks are there, wouldn't of thought that they would effect it but have removed them anyway. Any thoughts would be appreciated?


Restarting the PC did solve the problem, but as mentioned need a better solution ideally :smileyhappy:

 

Thanks

Member
CJHartshorne
Posts: 197
0 Kudos

Re: error 50103

Hi Develop-inG,

 

One way of ignoring a specific error is to use the General Error Handler VI. By wiring -50103 up to the [error code] input of the VI, the General Error Handler VI will ignore error -50103 but will handle all other errors as usual.

 

I don't think that this is going to help you in this case however. The only way to overcome the problems you are having at present is to eliminate the reserved resource issue through the use of good DAQ programming practices i.e. not continuously configuring and starting your task in a loop. There are a number of examples in the NI Example Finder which highlight such good programming practices such as the one cited in my last post.

 

I hope this helps.

 

Best Regards,

 

Christian Hartshorne

NIUK