S Mode Functions
Chapter 5
GPIB-SCSI-A User Manual
5-8
© National Instruments Corp.
brd
(continued)
2.
Use
brd
with the SCSI disconnection/reconnection capability to read
250 bytes from the GPIB.
Build SCSI Command Descriptor Block (CDB)
Byte 0 = 0xDD
Byte 1 = 0x00
Byte 2 = 0x00
Byte 3 = 0x00
Byte 4 = 0xFA
Byte 5 = 0x00
SCSIArbitrate
SCSISelectATN(GPIB-SCSI-A id)
SCSIMesgOut(0xC0)
SCSICmd(CDB)
While Not Done
While SCSI phase = Data In
SCSIRead(buffer, 1)
Increment buffer pointer
If SCSI phase = Message In
SCSIMesgIn(Mbyte)
If Mbyte = SAVE DATA POINTER
Set up necessary conditions and
wait to be reconnected by the
GPIB-SCSI-A. Upon reconnection,
the GPIB-SCSI-A enters the Message
In phase and sends an IDENTIFY
message of 0x80. The Data In
phase should resume.
If SCSI Phase = Status
SCSIStatus(Sbyte)
SCSIMesgIn(Mbyte)
Done