In order to write programs that control the GPIB bus, there must be an interface to the GPIB hardware. There are drivers for many programming languages so that they can use the ines driver and function library.
Using the ines driver library The ines IEEE488 interface system supplies the developer with libraries to create windows application which may control the GPIB bus. The interface to applications is designed as dynamic link libraries (DLLs), which is the typical method for Windows. These DLLs contain the GPIB functions like IeEnter(), IeOutput() or IeInpt() as described in the function reference. These functions are independent from the used hardware interface and programming language. The GPIB functions are calling an underlying interface, the device driver. The driver and its implementation depends on the used interface hardware and the Windows Version.
The following description demonstrates the general usage of the GPIB functions while the IEEE-488 commands covers a detailed description of every function. Since the implementation of the GPIB functions is the usual Windows method by using DLLs, it is possible to control the GPIB bus via any application or programming language which allows to call external DLLs. Special care has to be taken for multithreaded application. The GPIB functions don't protect itself from being called concurrently by separate threads in such a environment. The application must ensure that only one GPIB function may be called at a time.
The samples files may be used for a quick introduction into accessing the GPIB bus. A device is programmed to acquire a buffer of sample data and inform the computer via SRQ when the buffer has been filled up. Then the data is read into the computers data buffer and displayed. The sample applications require a Keithley Instrument K195A DMM or compatible at primary GPIB address 9.
The ines IEEE488 interface for C and C++ supplies the
developer with import libraries and include files to access
the DLL functions. The GPIB functions
are simple C functions. For C++, the declaration is nested in
an extern "C"
declaration automatically in the include file.
In order to use the correct data types and values,
the file IEEE488.H must be included. This file includes other
necessary files like types488.h itself and contains the
necessary function declarations. It is strongly recommended to
use the types shown in the command reference to write portable
applications. Before including the ines IEEE488.H header
file, the WINDOWS.H include file must be included and WINDOWS
has to be defined:
#include "windows.h" #define WINDOWS #include "ieee488.h"
All functions return an error code. This error code should be evaluated for non zero, which indicates the occurrence of an error.
WORD devPad; devPad = 709; ret = IeInit(736, 0, 5, 1); if(ret) ... ret = IeClear(devPad); ...
On occurrence of an error a messagebox appears with the error message. If the application handles this error by itself, this effect is not desired most times. In this case the function IeMode() may be called to turn off the error messages:
E488 retVal; IeMode(99); if((retVal = IeInit(736,0,5,1)) != 0) { showError(retVal); return; } ...
The C/C++ interface is supplied with import library files which must be linked to the application. The library names are IE488F3W.LIB and IE488H3W.LIB for 32-bit applications. The library IE488F3W.LIB is the import library for the GPIB functions and IE488H3W.LIB contain the error messages and some error related function references. For C/C++ compilers that cannot access the library functions via the supplied import libraries this library may be recreated from the DLLs by using a tool (like 'implib') which is supplied with the compiler.
The ines function DLL and help DLL may be accessed from Visual Basic directly. The necessary declarations are found in the IEEE488W.BAS (IEEE488.TXT for Visual Basic 1.0) file. This file has to be included in the Visual Basic project or in the GLOBAL.BAS file. GPIB functions may be called in the usual manner:
ierr% = IeInit(736, 0, 5, 1) ierr% = IeSet(709, 10000, 900, 9010) ierr% = IeRemote(709)
All functions return an error code as an integer value. Any nonzero value means the an error has occurred. On occurrence of an error a messagebox appears with the error message. If the application handles the error itself, this effect is not desired most times. In this case the function IeMode() may be called to turn off the error messages:
IeMode(99) ierr% = IeInit(736,0,5,1) if (ierr% <> 0) GoTo ErrHdlr
The ines function and help DLL may be accessed by Delphi directly. The file IEEE488W.PAS has to be included in the project. This file contains the unit 'ieee488w' where all necessary declarations are found to write applications that are controlling the GPIB bus. Delphi includes the ieee488w unit if the corresponding file 'IEEE488W.PAS' if specified in the project. Common data types are numeric values, which must be declared as Word and pointer to data areas, which have to be declared as array [0..nn] of Byte.
uses ..., ieee488w, ...; var pad: Word; pad := 709; ret := IeInit(736,0,5,1); ret := IeSet(pad,10000,900,900); ret := IeClear(pad);
If Pascal strings are used, the StrPCopy should be used. The Send function which is part of the Delphi sample uses this conversion:
(* send a pascal formatted string to the device specified by pad ,sad *) procedure Send(pad, sad: Word; s: string); var len, ret : Word; buffer : array [0..80] of Byte; begin len := Length(s); StrPCopy(@buffer, s); ret :=IeOutput(pad,sad,@buffer,@len); end;
All functions return an error code as an integer value. Any nonzero value means the an error has occurred. On occurrence of an error a messagebox appears with the error message. If the application handles the error itself, the messagebox is not desired most times. In this case the function IeMode() may be called to turn off the error messages:
var ret: Word; ret := IeMode(99); (* turn off error messages *) ret := IeInit(736,0,5,1); if ret <> 0 then ... (* handle this error *)
HT Basic is considered an GPIB application because it does not use the INES function library. Please see the HT Basic subsection of the Application Interfaces section.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeAbortio (UINT16 seven);
- Visual Basic
Declare Function IeAbortio Lib [...] (ByVal seven%) As Integer
- Delphi
function IeAbortio (seven: Word): SmallInt; stdcall;
Parameter Description
Abortio ends all communication on the bus according to the following priority:
The use of this command sets all the interface functions to an initialized state. A typical use is at the start of a program or use to recover from an error. The command stops all asynchronous transfers (DMA), that may have been started. Note: This command resets the interface functions of the connected devices, but it does not affect the device function for the measurement range (see Clear).
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeClear (UINT16 pad);
- Visual Basic
Declare Function IeClear Lib [...] (ByVal pad%) As Integer
- Delphi
function IeClear (pad: Word): SmallInt; stdcall;
Parameter Description
Clear resets the device functions of the addressed devices to their initial conditions.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeDisable (void);
- Visual Basic
Declare Function IeDisable Lib [...] () As Integer
- Delphi
function IeDisable (): SmallInt; stdcall;
Parameter Description
Asynchronous interrupts are disabled. Disable should be used only when entire sections in a program should not be interrupted.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeEnable (void);
- Visual Basic
Declare Function IeEnable Lib [...] () As Integer
- Delphi
function IeEnable (): SmallInt; stdcall;
Parameter Description
Enables asynchronous interrupts (see Disable).
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeEntByte (UINT16 pad, UNIT16 sad, LPUINT16 bval);
- Visual Basic
Declare Function IeEntByte Lib [...] (ByVal pad%, ByVal sad%, bval%) As Integer
- Delphi
function IeEntByte (pad, sad: Word; bval: PWord): SmallInt; stdcall;
Parameter Description
This function reads a single byte from the bus. EntByte addresses the device specified by pad and sad as talker if pad is unequal to IE_NOADR. If pad is set to IE_NOADR, no addressing will be done. Using the functions, the secondary address has to be specified. If no secondary address is needed, this parameter has to be set to IE_NOSAD. If at the same time as the data byte is received, the valid termination sequence is recognized (EOI active or EOS byte), then the highest bit of bval is set to '1'. To read more than one byte from the bus, use the Enter function.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeEnter (UINT16 pad, UNIT16 sad, LPBYTE buffer, LPUINT16 count);
- Visual Basic
Declare Function IeEnter Lib [...] (ByVal pad%, ByVal sad%, ByVal buffer$, count%) As Integer
- Delphi
function IeEnter (pad, sad: Word; buffer: Pbyte; count: PWord): SmallInt; stdcall;
Parameter Description
This function reads data from the bus until the specified count is reached or the current termination is recognized. Enter addresses the device specified by pad and sad as talker if pad is unequal to IE_NOADR. If pad is set to IE_NOADR, no addressing will be done. The secondary address has to be specified. If no secondary address is required, this parameter has to be set to IE_NOSAD.
A termination sequence can be chosen with the Set function. If the Set function is not properly assigned, the interface cannot identify a termination sequence when the end of transmission is reached. If the error message 13 end of transfer buffer is returned, check the following:
Note: Enter returns "end of transfer buffer" if the specified count has been reached and no termination is recognized. If you don't want to use any termination (i.e. want termination by specified length), this return value has to be interpreted as completion indicator and not as an error.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeEntFile (UINT16 pad, UNIT16 sad, LPBYTE path);
- Visual Basic
Declare function IeEntFile Lib [...] (ByVal pad%, ByVal sad%, ByVal path$) As Integer
- Delphi
function IeEntFile (pad, sad: Word; path: PChar): SmallInt; stdcall;
Parameter Description
This function reads data from the bus and writes it into a file until the current termination is recognized. The file will be created if it does not exists. If it exists, then the data will be appended to it. To replace an existing file, erase it first before calling this function. EntFile addresses the device specified by pad and sad as talker if pad is unequal to IE_NOADR. If pad is set to IE_NOADR, no addressing will be done. If no secondary address is needed, sad has to be set to IE_NOSAD. A termination sequence can be chosen with the Set function.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeHelp (UINT16 errno);
- Visual Basic
Declare Function IeHelp Lib [...] (ByVal errno%) As Integer
- Delphi
function IeHelp (errno: Word): SmallInt; stdcall;
Parameter Description
The help function appears on the screen when an error occurs. The help message can be suppressed by using the Mode function. It can also be called by a program. This can be useful when an application wants to suppress the help messages for certain errors. Help displays the ines IEEE488 errorcode and a human readable error description. In addition the current locator value is displayed. The locator value will be set using the Loc function and can be used to find errors in complex programs.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeInit (UINT16 ioadrs, UINT16 pad, UINT16 intr, UINT16 dma);
- Visual Basic
Declare Function IeInit Lib [...] (ByVal ioadrs%, ByVal pad%, ByVal intr%,ByVal dma%) As Integer
- Delphi
function IeInit (ioadrs, pad, intr, dma: Word): SmallInt; stdcall;
Parameter Description
The ines board and the software drivers will be initialized with the specified values. This has to be the first function to be called when using the ines IEEE488 interface. The current interface board becomes the system controller(SYSCTL), IFC is sent and REMOTE ENABLE is set to 'true'. After this, the interface is the active controller. With interface errors which cannot be removed by Abortio, it may be necessary to reset the entire interface system using Init. Following to an Init call the values of previous calls to Set are undefined and should be reinitialized.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeLAG (UINT16 pad, UINT16 sad);
- Visual Basic
Declare Function IeLAG Lib [...] (ByVal pad%,ByVal sad%) As Integer
- Delphi
function IeLAG (pad, sad: Word): SmallInt; stdcall;
Parameter Description
LAG addresses the device specified by pad and sad as listener. The specified device is then able to receive data from the bus. Using the functions, the secondary address has to be specified. If no secondary address is needed, this parameter has to be set to IE_NOSAD.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeLLO (void);
- Visual Basic
Declare Function IeLLO Lib [...] () As Integer
- Delphi
function IeLLO (): SmallInt; stdcall;
Parameter Description
Local lockout is a universal command that disables the operation panels of the connected devices on the IEEE488 bus.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeLoc (UINT16 locator);
- Visual Basic
Declare Function IeLoc Lib [...] (ByVal locator%) As Integer
- Delphi
function IeLoc (locator: Word): SmallInt; stdcall;
Parameter Description
locator is an integer value specified by the user. This value can be referenced to locate an error when it occurs and shown through the Help function. The locator value is displayed within the help function. Using this method, an error can be located in the program. Each call of Loc will update the locator value. This method is recommended when searching for an error in large programs.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeLocal (UINT16 pad);
- Visual Basic
Declare Function IeLocal Lib [...] (ByVal pad%) As Integer
- Delphi
function IeLocal (pad: Word): SmallInt; stdcall;
Parameter Description
Local disables remote control of devices connected to the bus.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeMode (UINT16 mode);
- Visual Basic
Declare Function IeMode Lib [...] (ByVal mode%) As Integer
- Delphi
function IeMode (mode: Word): SmallInt; stdcall;
Parameter Description
The Mode function enables/disables the help message appearing when an error occurs. This is useful when an error shall be handled only by the program itself. A value of 0 or 90 enables the help message, a value of 9 or 99 disables it.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeMyStat (LPUINT16 stb);
- Visual Basic
Declare Function IeMyStat Lib [...] (stb%) As Integer
- Delphi
function IeMyStat (stb: PWord): SmallInt; stdcall;
Parameter Description
The MyStat function is used to set the status byte. The bits 0-5 of stb contain information specific to the device, bit 6 is the 'rqs' message. Setting bit 6 causes the interface to activate the SRQ line. The GPIB CIC (controller-in-charge) can use a SERIAL POLL to poll the device. During the poll, the interface sets the SRQ line to 'FALSE'. When MyStat is used with stb=0, it is possible to determine if a SERVICE REQUEST needs to be performed. When the SRQ does not require service, bit 6 in stb is set to 1.
Typically, MyStat is used only if the interface is not the GPIB CIC.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeOnSrq (UINT16 mode, LPUINT16 target1, LPUINT16 target2);
- Visual Basic
not available>
- Delphi
function IeOnSrq (mode: Word; target1, target2: PWord): SmallInt; stdcall;
Parameter Description
OnSrq controls the handling of the asynchronous interrupt that occurs when a SERVICE REQUEST message is sent by a device. Depending on the value of mode the following handlings of an occuring SRQ interrupt are available:
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeOutByte (UINT16 pad, UNIT16 sad, LPUINT16 bval);
- Visual Basic
Declare Function IeOutByte Lib [...] (ByVal pad%, ByVal sad%, bval%) As Integer
- Delphi
function IeOutByte (pad, sad: Word; bval: PWord): SmallInt; stdcall;
Parameter Description
The OutByte function writes a single data byte to the bus. OutByte addresses the device specified by pad and sad as listener if pad is unequal to IE_NOADR. If pad is set to IE_NOADR, no addressing will be done. If no secondary address is required, this parameter has to be set to IE_NOSAD. The lower byte of bval will be send as data byte over the bus. If the highest bit in the higher byte is set (by adding of 32768 to the value to be send), the termination sequence (EOI and/or EOS byte), that was selected with Set, will be sent (EOI) or appended (EOS byte) at the same time. This signals the end of a message to the addressed listener.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeOutCmd (LPBYTE cmd);
- Visual Basic
Declare Function IeOutCmd Lib [...] (ByVal cmd$) As Integer
- Delphi
function IeOutCmd (cmd: PByte): SmallInt; stdcall;
Parameter Description
The function IeOutCmd sends a null-terminated sequence of commands to the bus. This function can generate command sequences which are not defined the standard IEEE488. Note that the interface must be the active controller.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeOutCmdByte (UINT16 cmdbyte);
- Visual Basic
Declare Function IeOutCmdByte Lib [...] (ByVal cmdbyte%) As Integer
- Delphi
function IeOutCmdByte (cmdbyte: Word): SmallInt; stdcall;
Parameter Description
The function IeOutCmdByte sends a command over the bus. This function can generate a command which is not defined by the standard IEEE488. Note that the interface must be the active controller.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeOutFile (UINT16 pad, UNIT16 sad, LPBYTE path);
- Visual Basic
Declare function IeOutFile Lib [...] (ByVal pad%, ByVal sad%, ByVal path$) As Integer
- Delphi
function IeOutFile (pad, sad: Word; path: PChar): SmallInt; stdcall;
Parameter Description
This function reads data from a file and sends it over the bus. OutFile addresses the device specified by pad and sad as listener if pad is unequal to IE_NOADR. If pad is equal to IE_NOADR, no addressing will be done. If no secondary address is required, sad must be set to IE_NOSAD.
Be aware that OutFile sends the entire file, irrespective of any termination sequences which may be included in the file itself. For this reason, only EOI should be used as termination (see Set) for file transfer.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeOutput (UINT16 pad, UNIT16 sad, LPBYTE buffer, LPUINT16 count);
- Visual Basic
Declare Function IeOutput Lib [...] (ByVal pad%, ByVal sad%, ByVal buffer$, count%) As Integer
- Delphi
function IeOutput (pad, sad: Word; buffer: Pbyte; count: PWord): SmallInt; stdcall;
Parameter Description
The Output function writes data to the bus until the specified count is reached. The data given in buffer will be send unmodified and unformatted to the device. Output addresses the device specified by pad and sad as listener if pad is unequal to IE_NOADR. If pad is equal to IE_NOADR, no addressing will be done. If no secondary address is required, the sad parameter has to be set to IE_NOSAD. The termination sequence for the transfer can be specified with the Set function.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IePasCnt (UINT16 pad);
- Visual Basic
Declare Function IePasCnt Lib [..] (ByVal pad%) As Integer
- Delphi
function IePasCnt (pad: Word): SmallInt; stdcall;
Parameter Description
Pass control of the system to another device. PasCnt addresses the device specified by pad as talker if pad is not IE_NOADR. If pad is equal to IE_NOADR, no addressing will be done (the current active talker will receive system control). The complementary function is RecCnt. If the control needs to be transferred between two ines-ieee488 systems, then RecCnt must first be activated and then the active controller can call the PasCnt function.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IePPD (UINT16 pad);
- Visual Basic
Declare Function IePPD Lib [..] (ByVal pad%) As Integer
- Delphi
function IePPD (pad: Word): SmallInt; stdcall;
Parameter Description
Deactivates the parallel-poll response of one or more devices. If pad is unequal to IE_NOADR, the specified device will be addessed as listener, otherwise all active listeners will receive this command.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IePPE (UINT16 pad,UINT16 ppc);
- Visual Basic
Declare Function IePPE Lib [..] (ByVal pad%, ByVal ppc%) As Integer
- Delphi
function IePPE (pad, ppc: Word): SmallInt; stdcall;
Parameter Description
Configures one or more devices for a parallel-poll response. If pad is unequal to IE_NOADR, the specified device will be addressed as listener, otherwise all active listeners will recognize this command. The ppc parameter is specified as follows:
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IePPoll (LPUINT16 resp);
- Visual Basic
Declare Function IePPoll Lib [..] (resp%) As Integer
- Delphi
function IePPoll (resp: PWord): SmallInt; stdcall;
Parameter Description
Performs a parallel poll and returns the result in resp.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IePPU (void);
- Visual Basic
Declare Function IePPU Lib [..] () As Integer
- Delphi
function IePPU: SmallInt; stdcall;0 on success, ines IEEE488 errorcode on failure Disables all devices from responses to parallel poll.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeRecCnt (void);
- Visual Basic
Declare Function IeRecCnt Lib [..] () As Integer
- Delphi
function IeRecCnt: SmallInt; stdcall;
Parameter Description
Enables the ines-ieee488 to become the active controller when operating as a device (CIDS). The complementary function is PasCnt. If the control needs to be transferred from one ieee488 system to another, then RecCnt must first be activated and then the active controller can issue the PasCnt function.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeRemote (UINT16 pad);
- Visual Basic
Declare Function IeRemote Lib [...] (ByVal pad%) As Integer
- Delphi
function IeRemote (pad: Word): SmallInt; stdcall;
Parameter Description
Remote sets the REMOTE ENABLE line true and thereby enables remote control of the attached devices. In addition, if pad is unequal to IE_NOADR, the specified device will be addressed as listener. This command requires the interface to be the system controller.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeResume (void);
- Visual Basic
Declare Function IeResume Lib [..] () As Integer
- Delphi
function IeResume: SmallInt; stdcall;
Parameter Description
Place an active controller in the standby status. 'ATN' is set to FALSE.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeSet (UINT16 pad, UINT16 tmo, UINT16 termin, UINT16 termout);
- Visual Basic
Declare Function IeSet Lib [...] (ByVal pad%, ByVal tmo%, ByVal termin%,ByVal termout%) As Integer
- Delphi
function IeSet (pad, tmo, termin, termout: Word): SmallInt; stdcall;
Parameter Description
Sets the interface parameters for devices on the bus. If pad is not IE_NOADR the parameters will be set only for the specified device. Otherwise the parameters will be set for all devices that has not been already configured by a call of Set with pad unequal to IE_NOADR.
The setting of a device will be activated if its address is sent. Only the primary address is used for device settings. An activate setting remains active until another device is addressed.
The settings available for termination values (termin/termout) are:
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeShadow (void);
- Visual Basic
Declare Function IeShadow Lib [..] () As Integer
- Delphi
function IeShadow: SmallInt; stdcall;
Parameter Description
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeSPoll (UINT16 pad, LPUINT16 resp);
- Visual Basic
Declare Function IeSPoll Lib [..] (ByVal pad%, resp%) As Integer
- Delphi
function IeSPoll (pad:Word; resp: PWord): SmallInt; stdcall;
Parameter Description
The serial poll function allows the questioning of devices as to their momentary status. SPoll addresses the device specified by pad as talker if pad is not IE_NOADR. If pad is equal to IE_NOADR, no addressing will be done.
All devices can be set to a condition that instructs them to send an individual status byte on request. This is made possible with the universal command SPE (Serial Poll Enable). After this, the first polled device is activated by sending its talker address. The device then sends its status byte in return. After receiving this message, it is possible to poll other devices. At the end of such a sequence, the command SPD (Serial Poll Disable) should be sent. The function IeSPoll handles this entire procedure in one call. The serial poll response resp has bit 6 set if the device queried requested service (SRQ).
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeStatus (LPUINT16 status);
- Visual Basic
Declare Function IeStatus Lib [..] (status%) As Integer
- Delphi
function IeStatus (status: PWord): SmallInt; stdcall;
Parameter Description
Status returns the current interface status. The selection of which status will be returned is specified by initializing status to one of the following values before calling the function:
Bit | Meaning |
---|---|
REM | interface is in a REMOTE condition |
LLO | LOCAL LOCKOUT is active |
ATN | the ATTENTION line is asserted |
SRQ | SERVICE REQUEST line is active |
LA | interface is addressed as a Listener |
TA | interface is addressed as a Talker |
EOI | EOI line is active |
Bit | Meaning |
---|---|
INIT | System was initialized without any errors |
CACS | Controller function is active |
CSBS | Controller function is in standby |
CIDS | Controller function is idle |
SYSC | The interface is the system controller |
Bit | Meaning |
---|---|
DONE | Aynchronous data transfer has been completed (This bit is 0 after activating an asynchonous transfer) |
DMA | Asynchronous data transfer was started and is still active |
Bit | Meaning |
---|---|
DTAS | Set if the ieee488 is operating as a device and the GET(Group Execute Trigger) command has been received. See also the Trigger function. |
UNC | Command that cannot be decoded was received |
DCAS | DEVICE CLEAR or SELECTED DEVICE CLEAR command has been received. |
ADSC | Address status changed |
SRQ | SRQ has been set to 'true' |
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeTAG (UINT16 pad, UINT16 sad);
- Visual Basic
Declare Function IeTAG Lib [...] (ByVal pad%,ByVal sad%) As Integer
- Delphi
function IeTAG (pad, sad: Word): SmallInt; stdcall;
Parameter Description
TAG addresses the device specified by pad and sad as talker. The specified device is then able to send data on the bus. If no secondary address is needed, sad parameter must be set to IE_NOSAD. The transfer parameters are activated as specified by the Set command for that device.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeTrigger (UINT16 pad);
- Visual Basic
Declare Function IeTrigger Lib [...] (ByVal pad%) As Integer
- Delphi
function IeTrigger (pad: Word): SmallInt; stdcall;
Parameter Description
Trigger addresses the device specified by pad as listener if pad is not IE_NOADR. If pad is equal to IE_NOADR, no addressing will be done. This command sends a GROUP EXECUTE TRIGGER command to all addressed devices. With devices that have a DEVICE TRIGGER function, the reception of this command causes the start of measurement sequences, etc.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeUNL (void);
- Visual Basic
Declare Function IeUNL Lib [...] () As Integer
- Delphi
function IeUNL (): SmallInt; stdcall;
Parameter Description
This command unaddresses all listener devices by sending the universal command UNL to the bus.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeUnSet (UINT16 pad);
- Visual Basic
Declare Function IeUnSet Lib [...] (ByVal pad%) As Integer
- Delphi
function IeUnSet (pad: Word): SmallInt; stdcall;
Parameter Description
The device settings for the specified device are deactivated. This means, the standard values will be used for this device. The standard values are specified by a former call of Set with pad given as IE_NOADR. If no former call of Set with pad=IE_NOADR was made, the default parameters (see Set) are used as standard parameters.
Synopsis
- C/C++
#include <ieee488.h> E488 FAR PASCAL IeUNT (void);
- Visual Basic
Declare Function IeUNT Lib [...] () As Integer
- Delphi
function IeUNT (): SmallInt; stdcall;
Parameter Description
This command unaddresses the current talker device by sending the universal command UNT to the bus.