⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 reqcode.c

📁 2812学习板usb68013源代码,包括usb驱动
💻 C
字号:
#include "standard.h"
#include "USB.h"
#include "Kernel.h" 

//DEVICE_DESCRIPTOR


unsigned int	HS_Device_Descriptor[] =
{
        0x0112,		   						
		0x0200,   			
		0x0000,   	  			         					
		0x4000,    										         
		0x04cc,				       
		0x1581,  			
		0x0000,  			              
		0x0201,   		   									    
		0x0100   						   	
		
};

unsigned int	  HS_Device_Qualifier[] =
{
		0x060a,						 
		0x0200,				 
		0x0000,						 				 
		0x0040, 						 
		0x0100					  						 		
};


unsigned int		HS_Config_Descriptor[] =
{
	
    	0x0209,							 	//Configuration Descriptor
		0x0020,   			            	//Total length of the configurations,interface and class/endpoint
		0x0101,							 	//No. of interface supported
		0xc000,							 	//Index of string descriptor
		0x00fa							 	//Maximun Power
		
};




unsigned int		HS_Interface_Descriptor2[] =
{      	0x0209,							 	//Configuration Descriptor
		0x0020,   			 	//Total length of the configurations,interface and class/endpoint
		0x0101,							 	//No. of interface supported
		0xc000,							 	//Index of string descriptor
		0x09fa,	
		0x0004,								//Standard Interface Type
    	0x0200,								//Alternate Setting Selector
		0x0000,								//Interface Class
		0x0000,								//ATAPI Interface Sub Class  
		0x0507,								//Standard Endpoint Type
		0x0201, 								//Set Bulk endpoint to 1 for ATAPI mode
		0x0200,						//Endpoint Max Packet Size
		0x0700,								//Interval for Polling Endpoint for data transfer
		0x8105,
		0x0002,
		0x0802
};



ENDPOINT_DESCRIPTOR		HS_Bulk_Out_Descriptor[] =
{
	
		0x0507,								//Standard Endpoint Type
		0x0201, 								//Set Bulk endpoint to 1 for ATAPI mode
		0x0200,						//Endpoint Max Packet Size
		0x0700,								//Interval for Polling Endpoint for data transfer
		0x8105,
		0x0002,
		0x0002
};

ENDPOINT_DESCRIPTOR		HS_Bulk_In_Descriptor[] =
{
	sizeof(ENDPOINT_DESCRIPTOR),	//Length of Standard Endpoint Descriptor
		0x05,								//Standard Endpoint Type
		0x81, 								//Set Bulk endpoint to 1 for ATAPI mode
		0x02,								//Endpoint Characteristic
		0x00,0x02,						//Endpoint Max Packet Size
		0x00								//Interval for Polling Endpoint for data transfer
		
};

OTHER_SPEED_CONFIG_DESCRIPTOR		Other_Speed_Config_Descriptor[] =
{
	
	sizeof(OTHER_SPEED_CONFIG_DESCRIPTOR),	//length of other speed configuration descriptor
		0x07,									//Other speed configuration Type
		0x20,0x00,				//Total length
		0x01,									//No of interface supported
		0x01,									//Configuration Value
		0x00,									//Index of string descriptor
		0xC0,									//Configurations Characteristic
		0x32									//Maximun Power
		
};


unsigned int		Manufacturer_String[] =	     

{	 0x031b,	  	   
'S' ,
't' , 
'u' , 
'd' , 
'y' , 
'-' , 
'k' , 
'i' , 
't' , 
'.' , 
'C' , 
'o' ,
'm'
};



unsigned int		Product_String[] =	     

{	 0x0326,	   	    
'S' ,          
't' ,  
'u' ,  
'd' ,  
'y' ,  
'-' ,  
'2' ,  
'8' ,  
'1' ,  
'2' ,  
' ' ,  
'V' ,  
'e' ,  
'r' ,  
':' ,  
'1' ,  
'.' ,  
'0'  
};







unsigned int	 	String_ID[] = 
{	
	    0x0304,
		0x0409
		
};																 


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -