Chapter 7
G Mode Functions
© National Instruments Corp.
7-27
GPIB-SCSI-A User Manual
format
(continued)
interleave
is optional. If you do not indicate an
interleave
as a parameter, the GPIB-SCSI-A assumes an
interleave value of 0.
During the execution of this command, if the GPIB-SCSI-A
encounters a phase which it did not expect, an EPHS error
indication results. For a list of the expected phases, refer to
the section titled Handling of SCSI Phases in G Mode in
Chapter 6, Programming in G Mode.
Refer to your SCSI device documentation for the expected
values in each byte of the Command Descriptor Block as well
as the SCSI phases that the device creates.
vendor
unique
byte
represents an 8-bit unsigned number.
Correct values range from 0 to 255.
interleave
is a 16-bit
unsigned number. Correct values range from 0 to 65,535. If a
number that is too large is entered for either value, there are no
numbers, or there is a syntax error in a number, the
GPIB-SCSI-A aborts the command with an EARG error
indication.
Examples:
1.
ibwrt (gpibscsia, "format 0, 1\n", 12);
/* Tell the GPIB-SCSI-A to do a SCSI FORMAT UNIT
* command. The vendor unique byte is 0 and
* the interleave factor is one.
*/
2.
ibwrt (gpibscsia, "format #h10\n", 12);
/* Tell the GPIB-SCSI-A to do a SCSI FORMAT UNIT
* command. The vendor unique byte is 0x10 and
* the interleave factor is not specified,
* causing the GPIB-SCSI-A to use a 0.
*/