BASICA/QuickBASIC GPIB-PC Function Calls
Section Four A
GPIB-PC User Manual
4A-94
©National Instruments Corp.
The board
IBWRTF
operation terminates on any of the following events:
•
All bytes sent;
•
Error is detected;
•
Time limit is exceeded; or
•
Device Clear (DCL) or Selected Device Clear (SDC)
command is received from another device which is the CIC.
After termination,
IBCNT%
contains the number of bytes written,
modulo 65,536.
Device Example:
1. Write data to the device
RDR%
from the file
Y.DAT
on the
current disk drive.
100 FLNAME$ = "Y.DAT"
110 CALL IBWRTF (RDR%,FLNAME$)
Board Example:
1.
Write data to the device at listen address &H2C (ASCII ,) from
the file
Y.DAT
on the current drive, and then unaddress the
interface board
BRD0%
.
100 REM Perform addressing in preparation
110 REM for board write.
120 CMD$ = "?@,"
' UNL MTA LAD
130 CALL IBCMD (BRD0%,CMD$)
140 REM Perform board write.
150 FLNAME$ = "Y.DAT"
160 CALL IBWRTF (BRD0%,FLNAME$)
170 REM Unaddress the Talker and Listener.
180 CMD$ = "_?"
' UNT UNL
190 CALL IBCMD (BRD0%,CMD$)