Download GPIB Library Software User`s Manual

Transcript
GPIB Library Software User's Manual
IBPPC
IBPPC
Purpose
Enables/Disables parallel polling of the specified device.
Syntax
BASIC
CALL ibppc (boarddev%, command%)
C
ibppc (int boarddev, int command)
PASCAL
ibppc(boarddev:integer; command:integer)
Parameters
boarddev is the device’s handle. This value is obtained by calling the ibfind
routine.
command is a valid parallel poll enable/disable message or 0. If command represents
a PPE message, then the device will use that message to respond to a parallel poll.
Valid PPE messages range from 60 to 6F hex. The PPE specifies the GPIB data
line (DIO1 through DIO8) on which the device is to respond and whether that line
is to be asserted or unasserted.
The PPE byte is of the format:
7
0
6
1
5
1
4
0
3
SENSE
2
P2
1
P1
0
P0
Where:
SENSE indicates the condition under which the data line is to be asserted. The
device compares the value of the sense bit to its IST (individual status) bit and
responds appropriately. For example, if SENSE = 1, the device will drive the line
TRUE if its IST = 1 or FALSE if IST = 0.
P2 - P0 specify which GPIB data line should be used to respond to a parallel poll,
as shown below:
P2
P1
P0
GPIB Data Line
1
1
1
1
0
0
0
0
1
1
0
0
1
1
0
0
1
0
1
0
1
0
1
0
DIO8
DIO7
DIO6
DIO5
DIO4
DIO3
DIO2
DIO1
For example, if the PPE byte 01101011 (hex 6B) is sent, the device will drive
DIO4 true if its IST bit = 1, or false if its IST bit = 0.
If command is 0 or represents a PPD (Parallel Poll Disable) message, the current
PPE (Parallel Poll Enable) configuration is cancelled. Valid PPD messages range
from 70 to 7F hex. The PPD is of a similar format to the PPE byte, for example:
7
0
Returns
6
1
5
1
4
0
3
SENSE
2
P2
1
P1
0
P0
ibsta will contain a 16-bit status word as described in Appendix B.
iberr will contain an error code, if an error occurred. Contains the previous value
of command if no error occurs.
Usage Notes
If boarddev specifies a GPIB interface board, this routine sets the board's Local
Poll Enable (LPE) message to command.
59