Scroll to navigation

IBASK(3) Traditional API Functions IBASK(3)

NAME

ibask - query configuration (board or device)

SYNOPSIS

#include <gpib/ib.h>

int ibask(int ud, int option, int *result);

DESCRIPTION

Queries various configuration settings associated with the board or device descriptor ud. The option argument specifies the particular setting you wish to query. The result of the query is written to the location specified by result. To change the descriptor's configuration, see ibconfig().

Table 5. ibask options

option value (hexadecimal) result of query used for board/device
IbaPAD 0x1 GPIB primary address board or device
IbaSAD 0x2 GPIB secondary address (0 for none, 0x60 to 0x7f for secondary addresses 0 to 31) board or device
IbaTMO 0x3 Timeout setting for io operations (a number from 0 to 17). See ibmto(). board or device
IbaEOT 0x4 Nonzero if EOI is asserted with last byte on writes. See ibeot().  
IbaPPC 0x5 Parallel poll configuration. See ibppc(). board
IbaREADDR 0x6 Useless, included for compatibility only. device
IbaAUTOPOLL 0x7 Nonzero if automatic serial polling is enabled. board
IbaCICPROT 0x8 Useless, included for compatibility only. board
IbaSC 0xa Nonzero if board is system controller. See ibrsc(). board
IbaSRE 0xb Nonzero if board automatically asserts the REN line when it becomes the system controller. See ibrsc(). board
IbaEOSrd 0xc Nonzero if termination of reads on reception of the end-of-string character is enabled. See ibeos(), in particular the REOS bit. board or device
IbaEOSwrt 0xd Nonzero if EOI is asserted whenever end-of-string character is sent. See ibeos(), in particular the XEOS bit. board or device
IbaEOScmp 0xe Nonzero if all 8 bits are used to match end-of-string character. Zero if only least significant 7 bits are used. See ibeos(), in particular the BIN bit. board or device
IbaEOSchar 0xf The end-of-string byte. board or device
IbaPP2 0x10 Nonzero if in local parallel poll configure mode. Zero if in remote parallel poll configure mode. board
IbaTIMING 0x11 Number indicating T1 delay. 1 for 2 microseconds, 2 for 500 nanoseconds, 3 for 350 nanoseconds. The values are declared in the header files as the constants T1_DELAY_2000ns, T1_DELAY_500ns, and T1_DELAY_350ns. board
IbaReadAdjust 0x13 Nonzero if byte pairs are automatically swapped during reads. board or device
IbaWriteAdjust 0x14 Nonzero if byte pairs are automatically swapped during writes. board or device
IbaEventQueue 0x15 Nonzero if event queue is enabled. board
IbaSPollBit 0x16 Nonzero if the use of the SPOLL bit in ibsta is enabled. board
IbaSendLLO 0x17 Nonzero if devices connected to this board are automatically put into local lockout mode when brought online with ibfind() or ibdev(). board
IbaSPollTime 0x18 Timeout for serial polls. The value of the result is between 0 and 17, and has the same meaning as in ibtmo(). device
IbaPPollTime 0x19 Timeout for parallel polls. The value of the result is between 0 and 17, and has the same meaning as in ibtmo(). board
IbaEndBitIsNormal 0x1a Nonzero if END bit of ibsta is set on reception of end-of-string character or EOI. Zero if END bit is only set on EOI. board or device
IbaUnAddr 0x1b Nonzero if UNT (untalk) and UNL (unlisten) commands are automatically sent after a completed ibrd* or ibwrt* operation using this descriptor. device
IbaHSCableLength 0x1f Useless, included only for compatibility. board
IbaIst 0x20 Individual status bit, a.k.a. 'ist'. board
IbaRsv 0x21 The current status byte this board will use to respond to serial polls. board
IbaBNA 0x200 For a device: the board index (minor number) of interface board through which the device is being accessed. For a board: the board index of the board itself. board or device
Iba7BitEOS 0x1000 Nonzero if board supports 7 bit EOS comparisons. See ibeos(), in particular the BIN bit. This is a Linux-GPIB extension. board

RETURN VALUE

The value of
ibsta is returned.

COPYRIGHT

Copyright © 2003-2006, 2008 Frank Mori Hess

11/30/2025 linux-gpib 4.3.7