USB mode/role switch on iMX8MQ-EVK.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

USB mode/role switch on iMX8MQ-EVK.

681 Views
nkulgod
Contributor II

Hi,

I have an iMX8MQ-EVK board running android_Q10.0.0_2.3.0 default build. I want to switch the USB mode from host to device manually. Is there any way to achieve this from user space or system level commands?

Thanks,

Nishant

Tags (3)
0 Kudos
2 Replies

674 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hi ,

See below, please!

----------------------------------

>> I want to switch the USB mode from host to device manually.

No, it can't be set manually.

>>Is there any way to achieve this from user space or system level commands?

No, there is not. usb driver doesn't support the way.

[comment]

It can be configured in device tree, like below:

&usb_dwc3_0 {
dr_mode = "peripheral"
hnp-disable;
srp-disable;
adp-disable;
/* usb-role-switch; */
snps,dis-u1-entry-quirk;
snps,dis-u2-entry-quirk;
status = "okay";
/*
port {
usb3_drd_sw: endpoint {
remote-endpoint = <&typec_dr_sw>;
};
};*/
};

Hope this information is helpful to you.

Have a nice day!

B.R,

weidong

0 Kudos

663 Views
nkulgod
Contributor II

Hi Weidong Sun,

Thanks for your reply.

I implemented the above change in the android kernel dts file and rebuilt android images. However, the behavior is still same as before (using USB A port). How can I access the board as a USB device by an external host during runtime?

Regards,

Nishant

0 Kudos