Package jisa.visa.drivers
Class GPIBDriver
- java.lang.Object
-
- jisa.visa.drivers.GPIBDriver
-
- All Implemented Interfaces:
Driver
- Direct Known Subclasses:
LinuxGPIBDriver,NIGPIBDriver
public abstract class GPIBDriver extends java.lang.Object implements Driver
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classGPIBDriver.GPIBConnectionImplementation of Connection for GPIB-based connections
-
Field Summary
Fields Modifier and Type Field Description protected static int_VI_ERRORprotected static java.util.HashMap<java.lang.Long,com.sun.jna.NativeLong>instrumentsprotected static java.lang.StringOS_NAMEprotected static java.lang.StringresponseEncodingprotected static intVI_FALSEprotected static intVI_NULLprotected static intVI_SUCCESSprotected static intVI_TRUEprotected static longVISA_ERROR
-
Constructor Summary
Constructors Constructor Description GPIBDriver()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract intgetIBCNT()protected abstract intgetIBERR()protected abstract intgetIBSTA()protected abstract voidinitialise()protected abstract GPIBNativeInterfacelib()Connectionopen(Address address)Attempts to open a connection to the instrument at the given address.voidreset()java.util.List<GPIBAddress>search()Use this driver to find instruments.java.util.List<GPIBAddress>search(int board)protected booleanwasError()booleanworksWith(Address address)
-
-
-
Field Detail
-
OS_NAME
protected static final java.lang.String OS_NAME
-
responseEncoding
protected static final java.lang.String responseEncoding
- See Also:
- Constant Field Values
-
VISA_ERROR
protected static final long VISA_ERROR
- See Also:
- Constant Field Values
-
_VI_ERROR
protected static final int _VI_ERROR
- See Also:
- Constant Field Values
-
VI_SUCCESS
protected static final int VI_SUCCESS
- See Also:
- Constant Field Values
-
VI_NULL
protected static final int VI_NULL
- See Also:
- Constant Field Values
-
VI_TRUE
protected static final int VI_TRUE
- See Also:
- Constant Field Values
-
VI_FALSE
protected static final int VI_FALSE
- See Also:
- Constant Field Values
-
instruments
protected static java.util.HashMap<java.lang.Long,com.sun.jna.NativeLong> instruments
-
-
Constructor Detail
-
GPIBDriver
public GPIBDriver() throws VISAException- Throws:
VISAException
-
-
Method Detail
-
initialise
protected abstract void initialise() throws VISAException- Throws:
VISAException
-
lib
protected abstract GPIBNativeInterface lib()
-
wasError
protected boolean wasError()
-
getIBSTA
protected abstract int getIBSTA()
-
getIBERR
protected abstract int getIBERR()
-
getIBCNT
protected abstract int getIBCNT()
-
open
public Connection open(Address address) throws VISAException
Description copied from interface:DriverAttempts to open a connection to the instrument at the given address. Returns a Connection object if successful.- Specified by:
openin interfaceDriver- Parameters:
address- Address of the instrument to open- Returns:
- Connection object representing newly opened connection
- Throws:
VISAException- If it goes wrong
-
search
public java.util.List<GPIBAddress> search()
Description copied from interface:DriverUse this driver to find instruments.
-
search
public java.util.List<GPIBAddress> search(int board) throws VISAException
- Throws:
VISAException
-
-