Hi DaneLLL,
It is work, thanks.
Could I use one USB3 port and cable to do?
Or it is Developer_Kit_Carrier_Board design issue?
Best regards,
Hi DaneLLL,
It is work, thanks.
Could I use one USB3 port and cable to do?
Or it is Developer_Kit_Carrier_Board design issue?
Best regards,
Hi FoxK, it is a HW design issue.
Hi DaneLLL
Do you have an updated change for r28.1? looks like the dtsi file has changed a lot wrt the usb.
thanks
Please try
Hi, DaneLLL
Thanks for the patch, I rebuild/applied dtb using
sudo ./flash -k -r DTB jetson-tx1 mmcblk0p1
then run the script, I can see and use mass storage device on the host, but from kernel log on device and on host it seems indicate it is still high speed, could you help take a look?
device log:
[Aug25 18:00] extcon-gpio-states extcon:extcon@1: Cable state 1
[ +0.006877] tegra-xudc-new 700d0000.xudc: exiting ELPG
[ +0.012690] tegra-xudc-new 700d0000.xudc: exiting ELPG done
[ +0.005655] tegra-xudc-new 700d0000.xudc: device mode on
[ +0.243629] android_work: did not send uevent (0 0 (null))
[ +0.054790] android_work: did not send uevent (0 0 (null))
[ +0.065609] android_work: sent uevent USB_STATE=CONNECTED
[ +0.006386] android_work: sent uevent USB_STATE=DISCONNECTED
[ +0.048554] android_work: did not send uevent (0 0 (null))
[ +0.086492] android_work: sent uevent USB_STATE=CONNECTED
[ +0.006052] configfs-gadget gadget: high-speed config #1: b
[ +0.001034] tegra-xudc-new 700d0000.xudc: ep 3 (type: 2, dir: in) enabled
[ +0.000116] tegra-xudc-new 700d0000.xudc: ep 2 (type: 2, dir: out) enabled
[ +0.019255] android_work: sent uevent USB_STATE=CONFIGURED
host log:
[ +2.071174] usb 1-2: new high-speed USB device number 20 using xhci_hcd
[ +0.143156] usb 1-2: New USB device found, idVendor=0955, idProduct=710d
[ +0.000015] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ +0.000009] usb 1-2: Product: Tegra Device
[ +0.000009] usb 1-2: Manufacturer: NVIDIA
[ +0.000008] usb 1-2: SerialNumber: 012345678ABCDEF
[ +0.012127] usb-storage 1-2:1.0: USB Mass Storage device detected
[ +0.000201] scsi host3: usb-storage 1-2:1.0
[ +1.015903] scsi 3:0:0:0: Direct-Access Linux File-Stor Gadget 0404 PQ: 0 ANSI: 2
[ +0.002197] sd 3:0:0:0: Attached scsi generic sg1 type 0
[ +0.009948] sd 3:0:0:0: [sdc] 2097152 512-byte logical blocks: (1.07 GB/1.00 GiB)
[ +0.001017] sd 3:0:0:0: [sdc] Write Protect is off
[ +0.000003] sd 3:0:0:0: [sdc] Mode Sense: 0f 00 00 00
[ +0.002156] sd 3:0:0:0: [sdc] Write cache: enabled, read cache: enabled, doesn’t support DPO or FUA
[ +0.017027] sd 3:0:0:0: [sdc] Attached SCSI removable disk
thanks
xiaoyong
Just a thought…one port gets routed to different controllers depending on what is plugged in…USB2 and earlier, or USB3. Check “lsusb -t” with a USB3 device plugged in just to make sure, and see 480M for speed of USB2, or 5000M for speed of USB3 (I doubt this will show anything useful, but it is an easy test).
Nevermind, this isn’t of use under gadget/device mode, it’s only of use in host mode.
my board is TX2 Developer Kit Carrier Board, I want to use USB3.0 as device mode,my SDK is R28.2.1, I use l4t-usb-device-mode.sh instead, and followed:
3> Plug in USB3.0 cable(Swap the TX/RX signal for normal USB3.0 A to A extension cable)
4> Plug in USB2.0 cable(The system need VBUS detect to identify a USB3.0 host connected)
then I can see:
ubuntu@tegra-ubuntu:~$ dmesg | grep ready
[ 3.882267] tegra186-cam-rtcpu b000000.rtcpu: already unhalted
[ 7.181780] IPv6: ADDRCONF(NETDEV_UP): usb0: link is not ready
[ 7.209983] IPv6: ADDRCONF(NETDEV_UP): usb1: link is not ready
[ 7.443996] IPv6: ADDRCONF(NETDEV_CHANGE): usb0: link becomes ready
[ 7.698592] IPv6: ADDRCONF(NETDEV_CHANGE): usb1: link becomes ready
[ 8.577384] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[ 11.907761] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
ubuntu@tegra-ubuntu:~$ lsusb -t
/: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci-tegra/3p, 5000M
/: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci-tegra/4p, 480M
|__ Port 2: Dev 2, If 0, Class=, Driver=, 1.5M
hot plug usb 3.0,i got:
[ 115.917609] xhci-tegra 3530000.xhci: exiting ELPG
[ 115.946722] xhci-tegra 3530000.xhci: Firmware timestamp: 2017-12-07 10:50:08 UTC, Version: 55.09 release
[ 115.959696] xhci-tegra 3530000.xhci: exiting ELPG done
[ 116.178440] usb 1-2: new low-speed USB device number 2 using xhci-tegra
[ 116.298647] usb 1-2: device descriptor read/64, error -71
[ 116.518663] usb 1-2: device descriptor read/64, error -71
[ 116.738438] usb 1-2: new low-speed USB device number 3 using xhci-tegra
[ 116.858659] usb 1-2: device descriptor read/64, error -71
[ 117.078642] usb 1-2: device descriptor read/64, error -71
[ 117.298434] usb 1-2: new low-speed USB device number 4 using xhci-tegra
[ 117.323213] usb 1-2: descriptor type invalid, skip
[ 117.328078] usb 1-2: No LPM exit latency info found, disabling LPM.
[ 117.340671] usb 1-2: New USB device found, idVendor=05ac, idProduct=166f
[ 117.347458] usb 1-2: New USB device strings: Mfr=2, Product=3, SerialNumber=1
[ 117.354735] usb 1-2: Product: Macintosh
[ 117.358671] usb 1-2: Manufacturer: Apple Inc.
[ 117.363128] usb 1-2: SerialNumber: 1048D709210EB99230456DE14E4FCD6D
[ 117.605389] xhci-tegra 3530000.xhci: tegra_xhci_mbox_work mailbox command 5
[ 117.612489] xhci-tegra 3530000.xhci: tegra_xhci_mbox_work ignore firmware MBOX_CMD_DEC_SSPI_CLOCK request
now the question is I cannot see USB 3.0 entered into super speed, and when i ping the ethernet USB0 wich correspond to USB3.0, just get timeout,
since R28.2.1’s TX2 device tree is dramatically diffrent to TX1’s , how can i fix this problem, or how to modify R28.2.1’s TX2 device tree?
USB3 as device mode is not possible on the developer kit carrier board. The wiring does not exist for this. The supplied USB3-capable ports are a type-A connector, and only the type-B connector supports device mode. The micro-OTG port is a special case where a connector type detect pin is present, and either a type-A micro or a type-B micro can be inserted…no possibility of using USB3 on this micro connector is available, and full-sized connectors have no possibility of device mode at any speed. You get device mode in USB2, or host mode in USB3, but not both.
Hi, I meet a similar issue. I want to set the OTG port on my Xavier NX as an HID device.
So I mkdir g1 on the /sys/kernel/config/usb_gadget and epoch the information to the files.
After that when I bind 3550000.xudc to the UDC in g1. There is an error output : INVALIDARGUMENT.
You should probably start a new thread in the NX forum.
However, all of the more modern of the flashed L4T releases with a micro-OTG port already have a framework of the “gadget” system set up. Browse files here:
/opt/nvidia/l4t-usb-device-mode
This sets up a virtual ethernet device and DNS service on the virtual ethernet. A “README” file is also set up on a simulated mass storage device.
The serial console runs through this port as well on some carrier boards, but this is “real”, and not “virtual”. In all cases the ID pin is used to detect if the cable being inserted is for device mode or host mode.
I have not looked at any specific controller address (what you show as “3550000.xudc”), and this may or may not be correct, but consider that some setup may already be in place. Be sure to check what is in “/opt/nvidia/l4t-usb-device-mode” before trying to bind a new controller.
Thank you for your replay. I already start a topic here :https://forums.developer.nvidia.com/t/setup-the-otg-to-an-hid-device/154063?u=945193029.