Measurement-computing GPIB-488 Manual de usuario Pagina 11

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 116
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 10
Chapter 2 Programming with the GPIB Library
Programming Reference Manual 2-2 GPIB-488
General Concepts
This section explains the difference between routines which use Device I/O
and those which use Board I/O, the use of device handles, and the global
variables used by the library routines.
Device vs. Board I/O
The most typical GPIB operations are sending commands to a device
attached to the bus and reading back responses. To do this, program the
GPIB board to execute these steps:
1. Address the selected device as a Listener.
2. Send the secondary address if used.
3. Address the board itself as the GPIB Talker.
4. Send the command bytes to the device.
5. Address the board itself as the Listener.
6. Read the response from the device.
7. Send the GPIB Unlisten (UNL) message.
8. Send the GPIB Untalk (UNT) message.
The original GPIB library interface is comprised of two different types of
routines: Board I/O and Device I/O. These routines are described in
Chapter 3, GPIB 488.1 Library Reference. You can program the board
using either Board I/O routines or Device I/O routines to perform the
sequence of operations outlined above.
The 488.2 library is all "Board I/O" in that you always supply the board ID
and the device address. Refer to Chapter 4, GPIB 488.2 Library Reference.
Device I/O
It is usually easier to use the Device I/O routines. Device I/O is very simple
to use and understand. Device I/O routines are higher-level routines which
conceal most of the underlying complexity of GPIB operations. The Device
I/O routines automatically take care of all of the low-level details involving
GPIB messages and addressing. For example, to accomplish the seven
steps listed above, you use only three routines:
ibdev—to open the device
ibwrt—to send the instrument command
ibrd—to read the data back from the device
Vista de pagina 10
1 2 ... 6 7 8 9 10 11 12 13 14 15 16 ... 115 116

Comentarios a estos manuales

Sin comentarios