USB typeC0 无typeC控制器 USB 2.0 type A口设计,配置为device模式插电脑无反应

固件类型:官方提供的固件
固件文件名称:AIO-3588Q_Debian11_v1.4.0a_240508
固件下载地址:百度网盘
Log日志:typec-usb20-device-only-nok-kernel-log.zip

  1. DTS更改为如下配置:

这样配置, 切换为host枚举U盘正常。

root@firefly:/home/firefly# cat /sys/kernel/debug/usb/fc000000.usb/mode

device

root@firefly:/home/firefly# echo host > /sys/kernel/debug/usb/fc000000.usb/mode

root@firefly:/home/firefly# lsusb

Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 009 Device 002: ID 0781:5581 SanDisk Corp. Ultra

Bus 009 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 010 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Bus 006 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Bus 008 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

但,切换为device模式后,还是无反应,表现为主机端未看到有任何枚举动作:

root@firefly:/home/firefly# echo device > /sys/kernel/debug/usb/fc000000.usb/mode

root@firefly:/home/firefly#

root@firefly:/home/firefly#

root@firefly:/home/firefly# cat /sys/devices/platform/fd5d0000.syscon/fd5d0000.syscon:usb2-phy@0/otg_mode

otg

root@firefly:/home/firefly# echo peripheral > /sys/devices/platform/fd5d0000.syscon/fd5d0000.syscon:usb2-phy@0/otg_mode

root@firefly:/home/firefly#

[u]root@firefly[/u]:/home/firefly#

  1. 完全使用客服发过来的devcie-only dtsi配置:

表现是默认为device模式,也是无反应,主机端未看到有任何枚举动作:

&usbdrd_dwc3_0 {

status = "okay";

dr_mode = "peripheral";

};

&u2phy0 {

status = "okay";

};

&u2phy0_otg {

status = “okay”;

};

&usbdp_phy0 {

/delete-property/ sbu1-dc-gpios;

/delete-property/ sbu2-dc-gpios;

/delete-property/ orientation-switch;

/delete-property/ svid;

/delete-property/ usbdp_phy0_orientation_switch;

/delete-property/ usbdp_phy0_dp_altmode_mux;

status = "okay";

};

&usbdp_phy0_dp {

status = "okay";

};

&usbdp_phy0_u3 {

status = "okay";

};

tchip_askquestions
typec-usb20-device-only-nok-kernel-log.zip (20.6 KB)

PS: 硬件设计是TYPEC0 只用了DP和DM信号,并接到一个TYPE A接口,应用需求是通过系统运行起来后软件配置为device或者host模式