#include<Atmel/AT89x52.H> #include<USB.H> #include<PDIUSBD12.H> #include<MASS_STORAGE.H> //#include<serial.h>
#define USB_COMMAND_ADD 1 #define USB_DATA_ADD 0
#define USB_DATA P0 #define USB_A0 P3_5 #define USB_WR P3_6 #define USB_RD P3_7 #define USB_INT P3_2
#define ENDPOINT_NUMBER 2 #define MAX_CONTROL_DATA_SIZE 16 #define MAX_LUN 0 #define MAX_BULK_DATA_SIZE 64
CONTROL_DATA_BUFF Control_Data;
unsigned char idata buffer[64];
CBW cbw; CSW csw;
union { unsigned char Register; struct { unsigned char Command :1; unsigned char Data :1; }Status; }SCSI;
|