home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus Special 6
/
Sonderheft_6-96.iso
/
pd
/
disktools
/
scsi_list
/
source
/
scsi_cmd.h
< prev
next >
Wrap
C/C++ Source or Header
|
1996-11-03
|
3KB
|
81 lines
/*
* scsi_cmd.h
*/
#include <devices/scsidisk.h>
#define SCSI_DEVICE "scsi.device"
/*------------------------------------------------------------------------*/
typedef struct
{
BYTE code;
UBYTE *ptr;
} IDTOSTRING;
static IDTOSTRING responseformat[] =
{
0x00, "SCSI-1",
0x01, "CCS",
0x02, "SCSI-2",
-1, "",
};
/*------------------------------------------------------------------------*/
/* type used for 6 byte SCSI command */
typedef struct
{
UBYTE opcode;
UBYTE b1;
UBYTE b2;
UBYTE b3;
UBYTE b4;
UBYTE control;
} SCSICMD6;
/*------------------------------------------------------------------------*/
/* SCSI commands */
#define SCSI_CMD_TUR 0x00 /* Test Unit Ready */
#define SCSI_CMD_RZU 0x01 /* Rezero Unit */
#define SCSI_CMD_RQS 0x03 /* Request Sense */
#define SCSI_CMD_FMU 0x04 /* Format unit */
#define SCSI_CMD_RAB 0x07 /* Reassign Block */
#define SCSI_CMD_RD 0x08 /* Read */
#define SCSI_CMD_WR 0x0A /* Write */
#define SCSI_CMD_SK 0x0B /* Seek */
#define SCSI_CMD_INQ 0x12 /* 6B: Inquiry */
#define SCSI_CMD_MSL 0x15 /* Mode Select */
#define SCSI_CMD_RU 0x16 /* Reserve Unit */
#define SCSI_CMD_RLU 0x17 /* Release Unit */
#define SCSI_CMD_MSE 0x1A /* 6B: Mode Sense */
#define SCSI_CMD_SSU 0x1B /* 6B: Start/Stop Unit */
#define SCSI_CMD_RDI 0x1C /* Receive Diagnostic */
#define SCSI_CMD_SDI 0x1D /* Send Diagnostic */
#define SCSI_CMD_RCP 0x25 /* Read Capacity */
#define SCSI_CMD_RXT 0x28 /* Read Extended */
#define SCSI_CMD_WXT 0x2A /* Write Extended */
#define SCSI_CMD_SKX 0x2B /* Seek Extended */
#define SCSI_CMD_WVF 0x2E /* Write & Verify */
#define SCSI_CMD_VF 0x2F /* Verify */
#define SCSI_CMD_RDD 0x37 /* Read Defect Data */
#define SCSI_CMD_WDB 0x3B /* Write Data Buffer */
#define SCSI_CMD_RDB 0x3C /* Read Data Buffer */
#define SCSI_CMD_COPY 0x18 /* 6B: Copy */
#define SCSI_CMD_COMPARE 0x39 /* 10B: Compare */
#define SCSI_CMD_COPYANDVERIFY 0x3A /* 10B: Copy and Verify */
#define SCSI_CMD_CHGEDEF 0x40 /* 10B: Change Definition */
#define SCSI_CMD_READSUBCHANNEL 0x42 /* 10B: Read Sub-Channel */
#define SCSI_CMD_READTOC 0x43 /* Read TOC from CD Audio */
#define SCSI_CMD_READHEADER 0x44 /* 10B: Read data block address header */
#define SCSI_CMD_PLAYAUDIO10 0x45 /* Play CD Audio */
#define SCSI_CMD_PLAYAUDIOTRACKINDEX 0x48 /* Play CD Audio Track */
/* Sony CDU 561 / Sony CDU 8003 = Apple CD 300 specific commands */
#define SCSI_CMD_READCDDA 0xD8 /* 12B: read digital audio */
#define SCSI_CMD_READCDDAMSF 0xD9 /* 12B: read digital audio */