通过 PYvisa 使用 GPIB 接口连接我的设备时出现错误。下面是我运行的简单代码。
>>> import visa;
>>> rm = visa.ResourceManager('C:/Windows/System32/visa32.dll');
>>> rm.list_resources();
('ASRL10::INSTR', 'ASRL71::INSTR')
但我没有看到它们本身被检测为 GPIB 接口。(如 GPIB::25::INSTR)。我已经安装了正确版本的 python 和 PyVISA。下面是相同的输出。
C:\>python -c "from pyvisa import util; util.get_debug_info()"
Machine Details:
Platform ID: Windows-7-6.1.7600
Processor: x86 Family 6 Model 58 Stepping 9, GenuineIntel
Python:
Implementation: CPython
Executable: C:\Python34\python.exe
Version: 3.4.3
Compiler: MSC v.1600 32 bit (Intel)
Bits: 32bit
Build: Feb 24 2015 22:43:06 (#v3.4.3:9b73f1c3e601)
Unicode: UCS4
PyVISA Version: 1.8
Backends:
ni:
Version: 1.8 (bundled with PyVISA)
#1: C:\Windows\system32\visa32.dll:
found by: auto
bitness: 32
Vendor: National Instruments
Impl. Version: 14680064
Spec. Version: 5243904
#2: C:\Windows\system32\visa32.dll:
found by: auto
bitness: 32
Vendor: National Instruments
Impl. Version: 14680064
Spec. Version: 5243904
谷歌搜索,我发现版本和库路径可能是可能的原因。但我想这不是我的问题。谁能指出我哪里出错了,因为我对 Python 和 pyVISA 非常陌生。