Use SCPI Commands
Standard Commands for Programmable Instruments, or SCPI commands, are an ASCII-based set of pre-defined commands and responses. They use the same data format across all SCPI compliant instruments. You can use SCPI commands with the Instrument Control Toolbox™ and the MATLAB® programming environment to control multiple instruments using similar functions. You can access a common functionality in instruments without changing your programming environment. SCPI commands are simple and flexible and accept a range of parameter formats. This allows you to easily program your instrument. The response to SCPI commands can be status information or data. You can define the format of the data independently of the device or the measurement. For more information refer to the IVI Foundation SCPI Specifications.
Use the writeline
function on instrument objects to send SCPI
commands. Then, use the readline
function to read the response. You
can also use the writeread
function to send SCPI commands that
require a response.
Commonly Used SCPI Commands
Commands | Functionality |
---|---|
*CLS | Clear the status |
*ESE | Enable standard event |
*ESE? | Query if event is enabled and standard |
*ESR? | Query standard event status register |
*IDN? | Query instrument identification |
*OPC | Operation complete |
*OPC? | Query if operation is complete |
*RST | Instrument reset |
*SRE | Enable service request |
*SRE? | Query id service request is enabled |
*STB? | Query read of status byte |
*TST? | Query instrument self test |
*WAI | Wait to continue |
See Also
serialport
| tcpclient
| tcpserver
| udpport
| visadev