Restore USB Port After DTB Change

Hello,

I was attempting to modify my DTB file and .cfg files so uboot and my kernel would support CAN by default instead of GPIO. This seemed to work, but I must have made a mistake somewhere because I no longer am able to connect USB devices or debug through the USB serial interface (/dev/ttyACM0 from host). The device is booting which I can tell because I connected a display. I am having a hard time pulling any logs of the device without the serial port (and not knowing the IP address).

I am able to reflash the box through Jetpack in recovery mode, but this doesn’t resolve the issue. I have tried doing the GUI Jetpack flash as well as manually flashing the dtb, kernel, and APP partitions through the flash.sh script.

Is there a specific command I need to use to force a reflash of all partitions? Any ideas for a better way to do a full “factory reset”?

Thanks,

-J

No, the only thing you cannot reset by flashing is something like stored inside EEPROM.

Could you try to run the script in /opt/nvidia ?

I’m not sure how to run the script without the serial port. I’ve been trying to figure out what its IP address is to SSH in, but have not been able to do that yet.

Okay, I was able to ssh in and ran ./nv-l4t-usb-device-mode.sh and got the following error:

No known UDC device found.

When I run ./nv-l4t-usb-device-mode-stop.sh I get these errors:

./nv-l4t-usb-device-mode-stop.sh: line 38: l4t/UDC: No such file or directory
rmdir: failed to remove ‘l4t/configs/c.1/strings/0x409’: No such file or directory
rmdir: failed to remove ‘l4t/functions/ecm.usb0/’: No such file or directory
rmdir: failed to remove ‘l4t/functions/mass_storage.0/’: No such file or directory
rmdir: failed to remove ‘l4t/functions/acm.GS0/’: No such file or directory
rmdir: failed to remove ‘l4t/functions/rndis.usb0/’: No such file or directory
rmdir: failed to remove ‘l4t/configs/c.1/’: No such file or directory
rmdir: failed to remove ‘l4t/strings/0x409’: No such file or directory
rmdir: failed to remove ‘l4t’: No such file or directory
l4tbr0: ERROR while getting interface flags: No such device
bridge l4tbr0 doesn’t exist; can’t delete it

I tried the scripts with and without sudo permissions.

Thanks for the help. After analyzing the dmesg log I saw that the USB port was throwing a bunch of errors and never initializing. It turned out that I had a hardware issue on a custom board connected to the header that shorted pin 10 (UART1_RX_3V3) and pin 28 (2C_GP2_CLK_3V3) to ground. Fixing the hardware resolved the problem.

I thought all the pins on that header (except power) defaulted to high impedance GPIO, but this must not be the case.