LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

NI-VISA

Solved!
Go to solution

Hello everyone,

 

I have trouble accessing my USB port with NI-VISA. I get the same error in my LabView VI as when I try to open the VISA TEst panel from NI MAX. The Error is the following:

 

Error opening resource:
ASRL1::INSTR

VISA: (Hex 0xBFFF0072) Die Ressource ist zwar gültig, aber VISA kann im Moment nicht darauf zugreifen.

 

I found various post about this and none could resolve my problem. I have checked if a programm is accessing the port via cmd promt wiht the follwoing command:

netstat -aon | findstr '[port_number]'

 

and none has been listed. I also tried to rename the port via the device manager. I even complete uninstalled all NI programms and reinstalled them. Nothing seems to help.

Has sombody an Idea what the issue might be?

 

Thanks for your help.

Cheers,

Jeremy

0 Kudos
Message 1 of 33
(2,527 Views)

If Google translate is correct your error message is: The resource is valid, but VISA cannot access it at the moment. 

 

Usually this means some other program has control of the resource.

 

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 2 of 33
(2,496 Views)

Hi,

 

Yes, the translation is correct. I thought so too, but I can't find another program that is using the COM ports.

How can I find these programs and how do enforce them to close the ports?

 

 

0 Kudos
Message 3 of 33
(2,493 Views)

Maybe this can help: Determine Which Process is Reserving Serial Port

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 4 of 33
(2,488 Views)

@RTSLVU  ha scritto:

Maybe this can help: Determine Which Process is Reserving Serial Port


I did not know this article. So I decided to try, but it did not work. Process Explorer did not find anything.

Paolo
-------------------
LV 7.1, 2011, 2017, 2019, 2021
0 Kudos
Message 5 of 33
(2,483 Views)

What USB adapter is this? The mentioned error usually means that the port is already opened by another program but it’s not the only possible reason to get this error.

Some of the USB-RS-232 interfaces and/or associated device drivers out there are pretty unreliable and trashy.

 

If VISA gets an unexpected error when trying to access the COMM port it reports this error. The actual cause could however be just as much an error in the driver or USB interface chip. 

Another possibility might be the Windows serial mouse driver which might consider this device to be a serial mouse for some reason and claims it at system boot already.

Rolf Kalbermatter
My Blog
0 Kudos
Message 6 of 33
(2,444 Views)

It seems no application utilzes the USB ports.

Is there another cause for this error?

 

Cheers,

Jeremy

0 Kudos
Message 7 of 33
(2,429 Views)

Hi Rolf,

 

the usb port is an usb 3.0 i dont use an RS232 adapter. I can't access the port wether I have something pluged in or not. I intend to use it for an xsense IMU sensor. I tried also to disable the the xsense sensor so it does not use it as a "mouse". But I doubt that it is used as a mouse since, in the device manager it is listed under "other devices".

 

I also noticed when I tried to rename the COM port from COM1 to COM6 I get a warning that another programm uses this port. However, when I search what program uses my port via cmd promt or the ProcessExplorer none programms are found. What does that mean? Is there some kind of hidden program that uses my port? Or for what reason could I get this warning message other then a programm utilizes the port.

 

Cheers,

Jeremy

 

0 Kudos
Message 8 of 33
(2,426 Views)

Seems like there are a lot of missing pieces to this puzzle.  I think we are just going to have to keep asking questions of you until you can give us a complete picture of what is going on.  (It's not unusual.  Lots of times, it's not clear to anyone exactly what info is relative or not so it takes several rounds of questions to finally figure out the root cause.)

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 9 of 33
(2,413 Views)

Very fuzzy information. You claim it’s an USB3 port and not to use a RS-232 adapter but that are two pretty unrelated things. It doesn’t matter what color the plastic insert has in your connector and neither if you have an external adapter between your device and the computer. If there is no external adapter and your device is recognized as an RS-232 device in the computer then that adapter is simply built in your device! It still can use a number of different chips internally to do that and some of them are more reliable than others. Strange errors up to complete dysfunctional operation of certain devices is not unheard off and especially common if the used chip is a cheap chinese knock off to save a few pennies.

Rolf Kalbermatter
My Blog
0 Kudos
Message 10 of 33
(2,390 Views)