自己做的板子。希望USB0和USB1都默认工作在HOST模式,不需要DEVICE模式。
但实际中发现,外设插在USB1可以工作,但插在USB0没有反应。
看到有篇文档 Usb-am335x-quick-start,processors.wiki.ti.com/.../Usb-am335x-quick-start
按照里面的说法,USB0都不能默认工作在HOST模式。
我希望linux启动后两个USB口都一样是HOST模式,需要怎么改呢?
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
自己做的板子。希望USB0和USB1都默认工作在HOST模式,不需要DEVICE模式。
但实际中发现,外设插在USB1可以工作,但插在USB0没有反应。
看到有篇文档 Usb-am335x-quick-start,processors.wiki.ti.com/.../Usb-am335x-quick-start
按照里面的说法,USB0都不能默认工作在HOST模式。
我希望linux启动后两个USB口都一样是HOST模式,需要怎么改呢?
ID脚配置了。原理图已经贴在下面这个帖子里了,请你看一下。
http://www.deyisupport.com/question_answer/dsp_arm/sitara_arm/f/25/p/21254/71176.aspx#71176
wiki的文档中有如下内容,请问红色的这句话要怎样理解呢?“insert A gadget driver”具体怎么操作?我实际上是不需要任何gadget的啊。
AM335xEVM (Beta)
The capability of musb ports on AM335x based beta EVM are provided below.
MUSB0 port is coming out on beta EVM as micro-AB receptacle and it can act either as host or device based on the micro plug inserted to it. If a micro-A plug is inserted then it will act as host and if a micro-B plug is inserted then the port will work in device mode. A gadget driver need to be inserted after booting the pre-built binary for MUSB0 port to become active.
我发现了,只要改一行代码就行了,这么简单的事,也没人告诉我一声,哎~~
board-am335xevm.c 里面
static struct omap_musb_board_data musb_board_data = {
.interface_type = MUSB_INTERFACE_ULPI,
/*
* mode[0:3] = USB0PORT's mode
* mode[4:7] = USB1PORT's mode
* AM335X beta EVM has USB0 in OTG mode and USB1 in host mode.
*/
// .mode = (MUSB_HOST << 4) | MUSB_OTG,
.mode = (MUSB_HOST << 4) | MUSB_HOST,
.power = 500,
.instances = 1,
};
guo prothes 说:这个需要其他配置配合,只是改这里我的kernel崩溃了,还在探索中
他的版本可能和您的不一样了。
关于硬件部分的设计,请参考 http://processors.wiki.ti.com/index.php/AM335x_Schematic_Checklist#USB
是kernel崩溃了,在linux是可以通过的,但在android下不行。与硬件无关。
guo prothes 说:这个需要其他配置配合,只是改这里我的kernel崩溃了,还在探索中
只要改那一个就ok了,id也要拉地,我们验证过。
在android下不行,设成HOST内核起不来,设成OTG不认设备(不能枚举)。在LINUX都没问题。