How to change from usb host to peripheral on the fly in linux userspace

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

How to change from usb host to peripheral on the fly in linux userspace

2,508 次查看
DavisRoman
Contributor III

Hello,

I have a custom i.mx6 based system and I have a connector that exposes a usb interface. 

Our use-case requires that we be able to change between usb host and usb peripheral on the fly in linux userspace. Preferably via the command line.

I was hoping there was something in /sys that i can take advantage of.

I'm currently on a 4.1.15 kernel.

Any ideas would be appreciated,

Thank you,


Davis

0 项奖励
回复
1 回复

2,250 次查看
igorpadykov
NXP Employee
NXP Employee

Hi Davis

I am afraid such functionality is not supported in nxp bsps, in general

seems one will have to write custom driver/application for usb role switch using

existing support in i.MX usb driver, please check Chapter 39 CHIPIDEA USB Driver

description of "HNP and SRP" in attached Linux Manual.

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 项奖励
回复