欢迎来到天天文库
浏览记录
ID:46885848
大小:389.90 KB
页数:8页
时间:2019-11-28
《Linux下USB Gadget驱动框架简介》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、一、USB系统简介1.设备状态的转换2.USB设备逻辑组织在USB协议中,接口(interface)由一个或多个端点组成,代表一个基本功能单元。配置(Configuration)由一个或多个接口组成。一个USB设备可以具有一个或多个配置。3.Linux下USB驱动整体框架Linux下USB设备侧驱动程序分为三个层次:•UDCDrivers直接访问硬件,控制Usb设备和Host间的底层通信,向上层提供硬件相关操作的回调函数。•GadgetAPI是UDCDrivers回调函数的封装。•Gadgetd
2、rivers是USB设备具体功能的实现。4.Setup过程介绍USB协议规定每个DEVICE必须有一个编号为0的CONTROL端点,此端点在RESET后即可用,无需HOST做任何配置。Host通过端点0完成SETUP过程。以下是fastboot的setup过程:••SETUP(0xB4)ADDR(0)ENDP(0)Data(8006000100004000)IN(0x96)ADDR(0)ENDP(0)Data(__00:120100020
3、0000040B40BFF0F00010101__16:0101)••SETUP(0xB4)ADDR(0)ENDP(0)Data(0005040000000000)•SETUP(0xB4)ADDR(4)ENDP(0)Data(8006000100001200)IN(0x96)ADDR(4)ENDP(0)Data(__00:1201000200000040B40BFF0F00010101__16:0101)•4、DESCRIPTOR:CONFIGURATION>SETUP(0xB4)ADDR(4)ENDP(0)Data(8006000200000900)IN(0x96)ADDR(4)ENDP(0)Data(090220000101018080)•SETUP(0xB4)ADDR(4)ENDP(0)Data(800600030000FF00)IN(0x96)ADDR(4)ENDP(0)Data(04030904)•SET5、UP(0xB4)ADDR(4)ENDP(0)Data(800601030904FF00)IN(0x96)ADDR(4)ENDP(0)Data(__00:1203660061007300740062006F006F00__16:7400)•SETUP(0xB4)ADDR(4)ENDP(0)Data(800600020000FF00)IN(0x96)ADDR(4)ENDP(0)Data(__00:090220000101018080090406、00002FF42__16:03000705820200020007050102000201)•SETUP(0xB4)ADDR(4)ENDP(0)Data(800600030000FF00)IN(0x96)ADDR(4)ENDP(0)Data(04030904)•SETUP(0xB4)ADDR(4)ENDP(0)Data(800601030904FF00)IN(0x96)ADDR(4)ENDP(0)Data(7、__00:1203660061007300740062006F006F00__16:7400)•SETUP(0xB4)ADDR(4)ENDP(0)Data(8006000100001200)IN(0x96)ADDR(4)ENDP(0)Data(__00:1201000200000040B40BFF0F00010101__16:0101)•SETUP(0xB4)ADDR(4)ENDP(0)Data8、(8006000200000900)IN(0x96)ADDR(4)ENDP(0)Data(090220000101018080)•SETUP(0xB4)ADDR(4)ENDP(0)Data(8006000200002000)IN(0x96)ADDR(4)ENDP(0)Data(__00:0902200001010180800904000002FF42__16:03000705820200020007050102000201)•
4、DESCRIPTOR:CONFIGURATION>SETUP(0xB4)ADDR(4)ENDP(0)Data(8006000200000900)IN(0x96)ADDR(4)ENDP(0)Data(090220000101018080)•SETUP(0xB4)ADDR(4)ENDP(0)Data(800600030000FF00)IN(0x96)ADDR(4)ENDP(0)Data(04030904)•SET
5、UP(0xB4)ADDR(4)ENDP(0)Data(800601030904FF00)IN(0x96)ADDR(4)ENDP(0)Data(__00:1203660061007300740062006F006F00__16:7400)•SETUP(0xB4)ADDR(4)ENDP(0)Data(800600020000FF00)IN(0x96)ADDR(4)ENDP(0)Data(__00:09022000010101808009040
6、00002FF42__16:03000705820200020007050102000201)•SETUP(0xB4)ADDR(4)ENDP(0)Data(800600030000FF00)IN(0x96)ADDR(4)ENDP(0)Data(04030904)•SETUP(0xB4)ADDR(4)ENDP(0)Data(800601030904FF00)IN(0x96)ADDR(4)ENDP(0)Data(
7、__00:1203660061007300740062006F006F00__16:7400)•SETUP(0xB4)ADDR(4)ENDP(0)Data(8006000100001200)IN(0x96)ADDR(4)ENDP(0)Data(__00:1201000200000040B40BFF0F00010101__16:0101)•SETUP(0xB4)ADDR(4)ENDP(0)Data
8、(8006000200000900)IN(0x96)ADDR(4)ENDP(0)Data(090220000101018080)•SETUP(0xB4)ADDR(4)ENDP(0)Data(8006000200002000)IN(0x96)ADDR(4)ENDP(0)Data(__00:0902200001010180800904000002FF42__16:03000705820200020007050102000201)•
此文档下载收益归作者所有