Linux Users

Highlighted

import visa error (python)

on linux Fedora 19, using python 2.7, I already install NI drivers using the cd rom that came with the gpib board, after issuing the next commands 

 

import pyPath,time
import re,time,string
import visa

 

the below error message appears, any suggestions how to fix this? I have already google and try different suggestions but no luck..

 

OSError Traceback (most recent call last)
<ipython-input-4-d78e0befec49> in <module>()
3 import pyPath,time
4 import re,time,string
----> 5 import visa
6

/projects/local/users/localusr/lib/visa.py in <module>()
----> 1 from pyvisa.visa import *

/projects/local/users/localusr/lib/pyvisa/visa.py in <module>()
229 return "ResourceManager()"
230
--> 231 resource_manager = ResourceManager()
232 """The global resource manager instance. Exactly one is needed."""
233

/projects/local/users/localusr/lib/pyvisa/vpp43.pyc in __new__(cls, *args, **kwds)
103 return it
104 cls.__it__ = it = object.__new__(cls)
--> 105 it.init(*args, **kwds)
106 return it
107 def init(self, *args, **kwds):

/projects/local/users/localusr/lib/pyvisa/visa.py in init(self)
225 # I have "session" as an alias because the specification calls the "vi"
226 # handle "session" for the resource manager.
--> 227 self.session = self.vi = vpp43.open_default_resource_manager()
228 def __repr__(self):
229 return "ResourceManager()"

/projects/local/users/localusr/lib/pyvisa/vpp43.pyc in open_default_resource_manager()
756 def open_default_resource_manager():
757 session = ViSession()
--> 758 visa_library().viOpenDefaultRM(byref(session))
759 return session.value
760

/projects/local/users/localusr/lib/pyvisa/vpp43.pyc in __call__(self, force_cdecl)
173 """
174 if self.__lib is None or self.__cdecl_lib is None:
--> 175 self.load_library()
176 if force_cdecl:
177 return self.__cdecl_lib

/projects/local/users/localusr/lib/pyvisa/vpp43.pyc in load_library(self, path)
144 if not path:
145 path = "/usr/local/vxipnp/linux/bin/libvisa.so.7"
--> 146 self.__lib = self.__cdecl_lib = cdll.LoadLibrary(path)
147 else:
148 self.__lib = self.__cdecl_lib = None

/usr/lib64/python2.7/ctypes/__init__.pyc in LoadLibrary(self, name)
433
434 def LoadLibrary(self, name):
--> 435 return self._dlltype(name)
436
437 cdll = LibraryLoader(CDLL)

/usr/lib64/python2.7/ctypes/__init__.pyc in __init__(self, name, mode, handle, use_errno, use_last_error)
355
356 if handle is None:
--> 357 self._handle = _dlopen(self._name, mode)
358 else:
359 self._handle = handle

OSError: /usr/local/vxipnp/linux/bin/libvisa.so.7: cannot open shared object file: No such file or directory

0 Kudos
Message 1 of 2
(487 Views)
1 REPLY 1
Highlighted

RE: import visa error (python)

can you say clearer

0 Kudos
Message 2 of 2
(132 Views)
Reply
This is an open group. Sign in and click the "Join Group" button to become a group member and start posting.