VISA 快速入门
什么是 VISA?
虚拟仪器标准架构 (VISA) 是由 Keysight®(以前称为 Agilent Technologies®)和 National Instruments™ 定义的一项标准,用于与仪器通信,无论接口如何。VISA 标准以前由 VXIplug&play 系统联盟维护,现在由 IVI 联合会维护。
Instrument Control Toolbox™ 使用 VISA 标准支持 TCP/IP(使用 VXI11 和 HiSLIP)、TCP/IP Socket、USB、GPIB、Serial、VXI 和 PXI 接口。通信是通过您在 MATLAB® 工作区中创建的 VISA 仪器对象建立的。例如,VISA-GPIB 对象允许您使用 VISA 标准与具有 GPIB 接口的仪器通信。
有关 IVI 联合会维护的完整 VISA 规范,请参阅 IVI Specifications。
支持的平台和最低驱动要求
VISA 在以下平台上受支持:
macOS(仅限 NI-VISA 和 R&S VISA)
Windows® 10 及更高版本
以下是您必须具有的最低 VISA 驱动版本:
Keysight IO Libraries 版本 18.1.24715.0 (Keysight Connection Expert 2019)
National Instruments NI-VISA 版本 19.5
Rohde & Schwarz R&S VISA 版本 5.12
Tektronix® TekVISA 版本 5.11.1。
注意
当安装在同一台计算机上时,TekVISA 和 Keysight VISA 不兼容。要使用其中任何一个,您必须卸载另一个。
与 VISA 结合使用的接口
对于许多 VISA 应用程序,您无需深入了解接口的工作原理,即可实现与仪器的通信。
连接并配置 VISA 资源
查看可使用 visadevlist 连接的可用 VISA 资源列表。此函数提供资源名称和别名的列表。您也可以从 VISA 供应商的控制软件中找到设备的资源名称或别名。有关 VISA 资源名称的详细信息,请参阅 ResourceName。
要连接到 VISA 资源,请使用 visadev 指定其资源名称或别名。
在连接到仪器或设备后,您可以配置其属性。有关 visadev 属性的完整列表以及如何配置它们的信息,请参阅 visadev Properties。
其他功能
使用以下函数与 visadev 对象通信。
read | Read data from VISA resource |
readline | Read line of ASCII string data from VISA resource |
readbinblock | Read one binblock of data from VISA resource |
write | Write data to VISA resource |
writeline | 向 VISA 资源写入 ASCII 数据行 |
writebinblock | Write one binblock of data to VISA resource |
writeread | Write command to VISA resource and read response |
configureTerminator | Set terminator for ASCII string communication with VISA resource |
flush | Clear buffers for communication with VISA resource |
visastatus | Check status of VISA resource |
visatrigger | Send trigger to GPIB or VXI instruments |
setDTR | Set serial DTR pin |
setRTS | Set serial RTS pin |
getpinstatus | Get serial pin status |
另请参阅
函数
主题
- Get Started with TCP/IP Interface for VXI-11 and HiSLIP
- Get Started with TCP/IP Socket Interface
- Get Started with USB Interface
- Get Started with GPIB Interface
- Get Started with Serial Port Interface
- Get Started with VXI and PXI Interfaces
- Write and Read ASCII Data Using VISA
- Write and Read Binary Data Using VISA
- VISA 接口故障排除