Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA finds a non-existing port...

Solved!
Go to solution

Hello,

 

We have replaced our old lab computer by a new model and used the opportunity to also move to a more current operating system (from Win XP to Win 7 64 bit) and to the current version of CVI (2013 SP2), its runtime engine, and all the device drivers (latest 2014 versions of VISA...).

 

Unfortunately, this broke an old software because of the following error message:

 

VISA error: insufficient location information or the device or resource is not present in the system.

 

After some investigations it turned out that the source of this problem is the call to

 

viFindRsrc ( resource_manager_handle, "ASRL[0-9]*::?*INSTR", &find_handle, &return_count, instrument_descriptor );

and

status = viFindNext ( find_handle, instrument_descriptor );

 

because LPT 1 is included in the list of serial devices although it does not exist physically. So trying to open the port fails with the above mentioned error.

 

MAX has the same problem, it lists LPT 1 but with a red cross, indicating that it is unable to open it. Windows device manager does not show LPT.

 

So, my conclusion would be that this is a bug in VISA... Am I wrong, is it a know bug, is there a know workaround?

 

Thanks!

0 Kudos
Message 1 of 10
(5,660 Views)

The same happens on my W7 64 bits computer.

 

Disabling the port in MAX should resolve your problem.

 

Disable LPT1.jpg

Message 2 of 10
(5,643 Views)

Thanks a lot for your feedback - and the workaround.

 

Still I would be happy if NI could comment on the question if this is considered a bug and going to be fixed Smiley Wink

0 Kudos
Message 3 of 10
(5,637 Views)

I would also be very interested in a reply from NI.

0 Kudos
Message 4 of 10
(5,627 Views)
I've noticed this too when I went to Windows 7. I don't know whether it is something there or VISA. I haven't had a problem though because my resource searches use the aliases and not the canonical name.
0 Kudos
Message 5 of 10
(5,625 Views)

@JB wrote:

I would also be very interested in a reply from NI.


 

Hello NI... we are listening Smiley Wink

0 Kudos
Message 6 of 10
(5,579 Views)

I would have thought that 2 months should give enough time for an answer Smiley Frustrated

0 Kudos
Message 7 of 10
(5,374 Views)

The reason why I am still asking is that the 'solution' with MAX works only on my computer. If I distribute the program, typically there will be no MAX installed...

 

@ Dennis_Knudson: Please, could you explain a bit more in detail what you mean by "my resource searches use the aliases and not the canonical name".

 

Right now, after viFindRsrc ( resource_manager_handle, "ASRL[0-9]*::?*INSTR", &find_handle, &return_count, instrument_descriptor );

my software checks the port type (COM (RS232/RS485) or LPT) for each port, the routine is like this:

 

VISATestSerialPortAvailable ( ... )

for ( index = 2; index <= return_count; index ++ )
{
    status = viFindNext ( find_handle, instrument_descriptor );
    if ( status == VI_SUCCESS )

    {

        VISATestSerialPortAvailable ( ... );

    }

}

 

By the way, does searching for aliases really help - doesn't it also rely on MAX?

 

Thanks!

0 Kudos
Message 8 of 10
(5,335 Views)
With LabVIEW, you can select to return aliases (ComX) or the canonical names (ASRL::X) so if I search for Com aliases odds does not return the LPT1 alias. It's been a while since I used CVI for instrument control and I don't know if you have that option.

I don't believe you need MAX for aliases. They exist in the visaconf.ini file so that folder and file would have to be installed at least. I always install MAX so I could be wrong, though.
Message 9 of 10
(5,323 Views)
Solution
Accepted by topic author Wolfgang

After opening a support request our kind local support informed me today that this is a known issue, CAR 242354, supposedly fixed in VISA 15.

Kudos to her

0 Kudos
Message 10 of 10
(5,275 Views)