1 /* Driver for SCM Microsystems USB-ATAPI cable
4 * $Id: shuttle_usbat.h,v 1.5 2000/09/17 14:44:52 groovyjava Exp $
6 * Current development and maintenance by:
7 * (c) 2000 Robert Baruch (autophile@dol.net)
9 * See scm.c for more explanation
11 * This program is free software; you can redistribute it and/or modify it
12 * under the terms of the GNU General Public License as published by the
13 * Free Software Foundation; either version 2, or (at your option) any
16 * This program is distributed in the hope that it will be useful, but
17 * WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * General Public License for more details.
21 * You should have received a copy of the GNU General Public License along
22 * with this program; if not, write to the Free Software Foundation, Inc.,
23 * 675 Mass Ave, Cambridge, MA 02139, USA.
26 #ifndef _USB_SHUTTLE_USBAT_H
27 #define _USB_SHUTTLE_USBAT_H
29 #define USBAT_EPP_PORT 0x10
30 #define USBAT_EPP_REGISTER 0x30
31 #define USBAT_ATA 0x40
32 #define USBAT_ISA 0x50
34 /* SCM User I/O Data registers */
36 #define USBAT_UIO_EPAD 0x80 // Enable Peripheral Control Signals
37 #define USBAT_UIO_CDT 0x40 // Card Detect (Read Only)
38 // CDT = ACKD & !UI1 & !UI0
39 #define USBAT_UIO_1 0x20 // I/O 1
40 #define USBAT_UIO_0 0x10 // I/O 0
41 #define USBAT_UIO_EPP_ATA 0x08 // 1=EPP mode, 0=ATA mode
42 #define USBAT_UIO_UI1 0x04 // Input 1
43 #define USBAT_UIO_UI0 0x02 // Input 0
44 #define USBAT_UIO_INTR_ACK 0x01 // Interrupt (ATA & ISA)/Acknowledge (EPP)
46 /* SCM User I/O Enable registers */
48 #define USBAT_UIO_DRVRST 0x80 // Reset Peripheral
49 #define USBAT_UIO_ACKD 0x40 // Enable Card Detect
50 #define USBAT_UIO_OE1 0x20 // I/O 1 set=output/clr=input
51 // If ACKD=1, set OE1 to 1 also.
52 #define USBAT_UIO_OE0 0x10 // I/O 0 set=output/clr=input
53 #define USBAT_UIO_ADPRST 0x01 // Reset SCM chip
56 extern int hp8200e_transport(Scsi_Cmnd *srb, struct us_data *us);
57 extern int init_8200e(struct us_data *us);