USB not working on Jetson Nano

Hi,

What does your “ifconfig” result look like now?

It show me this :
jetsonnano@jetsonnano:~$ ifconfig
docker0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 172.17.0.1 netmask 255.255.0.0 broadcast 172.17.255.255
ether 02:42:e5:2e:47:4d txqueuelen 0 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

eth0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether 00:04:4b:ec:a4:ff txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device interrupt 150 base 0xe000

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10
loop txqueuelen 1 (Local Loopback)
RX packets 3841 bytes 362645 (362.6 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 3841 bytes 362645 (362.6 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

rndis0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether f2:cb:98:86:b4:bd txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

usb0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether f2:cb:98:86:b4:bf txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.25 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 2001:861:3146:6470:5869:2de9:a7e8:dbcf prefixlen 64 scopeid 0x0
inet6 fe80::cd30:8b25:8cb4:6237 prefixlen 64 scopeid 0x20
inet6 2001:861:3146:6470:fb10:bf12:349b:5a1d prefixlen 64 scopeid 0x0
ether 8c:55:4a:be:6a:9f txqueuelen 1000 (Ethernet)
RX packets 61382 bytes 82180903 (82.1 MB)
RX errors 0 dropped 244 overruns 0 frame 0
TX packets 10337 bytes 2042881 (2.0 MB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

Do you have micro usb cable connected to your host now? If so, could you run nv-l4t-usb-device-mode-runtime-start.sh and share the result?

It show me the same error when it’s connected and when it’s not :
/opt/nvidia/l4t-usb-device-mode/nv-l4t-usb-device-mode-start.sh: line 127: echo: write error: Device or resource busy

Please read the file name I just shared.

Oh sorry…
sudo /opt/nvidia/l4t-usb-device-mode/nv-l4t-usb-device-mode-runtime-start.sh
Internet Systems Consortium DHCP Server 4.4.1
Copyright 2004-2018 Internet Systems Consortium.
All rights reserved.
For info, please visit ISC DHCP - ISC
Config file: /opt/nvidia/l4t-usb-device-mode/dhcpd.conf
Database file: /run/l4t-usb-devmode-dhcpd.leases
PID file: /run/l4t-usb-devmode-dhcpd.pid
Wrote 0 leases to leases file.
Listening on LPF/l4tbr0/f2:cb:98:86:b4:bd/192.168.55.0/24
Sending on LPF/l4tbr0/f2:cb:98:86:b4:bd/192.168.55.0/24
Sending on Socket/fallback/fallback-net

Does l4tbr0 interface show up on your device ifconfig now? And do you see corresponding interface on your host now?

Yes there is l4tbr0 interface show on my ifconfig ! But there is nothing on my host…

can you unplug and replug your microusb cable and post the result of dmesg here.

If your mac address was empty before then it failed because l4t usb device mode encountered error when running the set up script.

As your ifconfig now contains both usb0 and rndis0, I think now nv-l4t-usb-device-mode has runned successful, but no l4tbr0 means that the device fails to detect microusb cable is plugged in. This could be that the microusb cable is faulty. Can you post the result of

sudo systemctl status nv-l4t-usb-device-mode

and

sudo systemctl status nv-l4t-usb-device-mode-runtime

also

Alright thanks for the explanation !
Like you said I type the command and give me this :
sudo systemctl status nv-l4t-usb-device-mode
[sudo] password for jetsonnano:
● nv-l4t-usb-device-mode.service - Configure USB flashing port for device mode
Loaded: loaded (/etc/systemd/system/nv-l4t-usb-device-mode.service; enable>
Active: active (exited) since Thu 2021-05-06 15:40:40 CEST; 17h ago
Process: 4232 ExecStart=/opt/nvidia/l4t-usb-device-mode/nv-l4t-usb-device-m>
Main PID: 4232 (code=exited, status=0/SUCCESS)

mai 06 15:40:38 jetsonnano systemd[1]: Starting Configure USB flashing port for>
mai 06 15:40:40 jetsonnano nv-l4t-usb-device-mode-start.sh[4232]: /
mai 06 15:40:40 jetsonnano systemd[1]: Finished Configure USB flashing port for>

sudo systemctl status nv-l4t-usb-device-mode-runtime
● nv-l4t-usb-device-mode-runtime.service - Runtime configuration for USB device mode
Loaded: loaded (/etc/systemd/system/nv-l4t-usb-device-mode-runtime.service; linked; vendor preset: enabled)
Active: inactive (dead)
And when I unplug and plug it gives me this : dmesg.log (68.2 KB)

From dmesg, look like it detect the unplug and replug ok
what is the status of nv-l4t-usb-device-mode-runtime after unplug and replug? Looks like

sudo systemctl status nv-l4t-usb-device-mode-runtime

I have check right after and it is exactly the same message that before.

android_usb state should be in CONFIGURED state when microusb is plugged in. I am wondering why that happens. Can you run

sudo service nv-l4t-usb-device-mode-runtime start

and then show

sudo systemctl status nv-l4t-usb-device-mode-runtime

and

ifconfig.

It give me this :
jetsonnano@jetsonnano:~$ sudo service nv-l4t-usb-device-mode-runtime start
jetsonnano@jetsonnano:~$ sudo systemctl status nv-l4t-usb-device-mode-runtime
● nv-l4t-usb-device-mode-runtime.service - Runtime configuration for USB device mode
Loaded: loaded (/etc/systemd/system/nv-l4t-usb-device-mode-runtime.service; linked; vendor preset: enabled)
Active: active (exited) since Fri 2021-05-07 15:36:42 CEST; 13s ago
Process: 13555 ExecStart=/opt/nvidia/l4t-usb-device-mode/nv-l4t-usb-device-mode-runtime-start.sh (code=exited, status=0/SUCCESS)
Main PID: 13555 (code=exited, status=0/SUCCESS)
Tasks: 4 (limit: 4172)
Memory: 9.4M
CGroup: /system.slice/nv-l4t-usb-device-mode-runtime.service
└─13621 /usr/sbin/dhcpd -cf /opt/nvidia/l4t-usb-device-mode/dhcpd.conf -pf /run/l4t-usb-devmode-dhcpd.pid -lf /run/l4t-usb-devmode-dhcpd.leases l4tbr0

mai 07 15:36:41 jetsonnano dhcpd[13621]: PID file: /run/l4t-usb-devmode-dhcpd.pid
mai 07 15:36:41 jetsonnano dhcpd[13621]: Wrote 0 leases to leases file.
mai 07 15:36:42 jetsonnano dhcpd[13621]: Listening on LPF/l4tbr0/f2:cb:98:86:b4:bd/192.168.55.0/24
mai 07 15:36:42 jetsonnano nv-l4t-usb-device-mode-runtime-start.sh[13621]: Listening on LPF/l4tbr0/f2:cb:98:86:b4:bd/192.168.55.0/24
mai 07 15:36:42 jetsonnano nv-l4t-usb-device-mode-runtime-start.sh[13621]: Sending on LPF/l4tbr0/f2:cb:98:86:b4:bd/192.168.55.0/24
mai 07 15:36:42 jetsonnano nv-l4t-usb-device-mode-runtime-start.sh[13621]: Sending on Socket/fallback/fallback-net
mai 07 15:36:42 jetsonnano dhcpd[13621]: Sending on LPF/l4tbr0/f2:cb:98:86:b4:bd/192.168.55.0/24
mai 07 15:36:42 jetsonnano dhcpd[13621]: Sending on Socket/fallback/fallback-net
mai 07 15:36:42 jetsonnano dhcpd[13621]: Server starting service.
mai 07 15:36:42 jetsonnano systemd[1]: Finished Runtime configuration for USB device mode.
jetsonnano@jetsonnano:~$ ifconfig
docker0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 172.17.0.1 netmask 255.255.0.0 broadcast 172.17.255.255
ether 02:42:ed:59:23:4e txqueuelen 0 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

eth0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether 00:04:4b:ec:a4:ff txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device interrupt 150 base 0xe000

l4tbr0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 192.168.55.1 netmask 255.255.255.0 broadcast 192.168.55.255
inet6 fe80::1 prefixlen 128 scopeid 0x20
ether f2:cb:98:86:b4:bd txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10
loop txqueuelen 1 (Local Loopback)
RX packets 6936 bytes 627914 (627.9 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 6936 bytes 627914 (627.9 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

rndis0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether f2:cb:98:86:b4:bd txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

usb0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether f2:cb:98:86:b4:bf txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.25 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::cd30:8b25:8cb4:6237 prefixlen 64 scopeid 0x20
inet6 2001:861:3146:6470:f0dd:b52e:5173:528e prefixlen 64 scopeid 0x0
inet6 2001:861:3146:6470:fb10:bf12:349b:5a1d prefixlen 64 scopeid 0x0
ether 8c:55:4a:be:6a:9f txqueuelen 1000 (Ethernet)
RX packets 125018 bytes 173322125 (173.3 MB)
RX errors 0 dropped 827 overruns 0 frame 0
TX packets 30424 bytes 3982321 (3.9 MB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

On your PC is /dev/ttyACM0 present?

No…

Do you happen to have other microusb cables to test?

I have tried 3 different cable and nothing has changed

Do you have other ubuntu host to try?