Python Forum

Full Version: OS Error: 0x7e
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello everyone,
I am trying to load .dll files in python 2.7, but there is an error 0x7e. I am using Anaconda python 2.7: 64 bit, Psychopy2 1.83.04: 64 bit, Qmix SDK 64 bit (contains .dll files) on 64 bit windows 7. I did the same programming in other laptop with with same version of software with windows 10: 64 bit and it worked really fine. I have also install 'Microsoft Visual C++ Compiler package for python' as well as I have put .dll folder path in to Environment variable to highest priority. I am sending you the trace back. Please take a look and give me some advise.

Trace back (most recent call last):

File "<ipython-input-15-0a18d8a4b562>", line 6, in <module>
qmix_bus = qmix.QmixBus(config_dir=config_dir, dll_dir=dll_dir)

File "qmix.py", line 90, in __init__
self._dll = self._ffi.dlopen(self.dll_file)

File "C:\ProgramData\Anaconda2\lib\site-packages\cffi\api.py", line 140, in dlopen
lib, function_cache = _make_ffi_library(self, name, flags)

File "C:\ProgramData\Anaconda2\lib\site-packages\cffi\api.py", line 786, in _make_ffi_library
backendlib = _load_backend_lib(backend, libname, flags)

File "C:\ProgramData\Anaconda2\lib\site-packages\cffi\api.py", line 782, in _load_backend_lib
return backend.load_library(path, flags)

OSError: cannot load library C:\Users\vtuser\QmixSDK\QmixSDK-64bit\labbCAN_Bus_API.dll: error 0x7e

Thanks,
Ravi
Most probably the dll was created or recompiled for Windows 10 and it cannot work under Windows 7.
Have you tried contacting the author of QMix?