ttyACM0 able to run only once until it is re-pluged again in jetson orin nano

Hi, I am using Jetson orin nano developer kit.
I am able to run the microcontroller’s port ttyACM0 only once, I have to re-plug it in again to run the microcontroller which will again run only once but the port is detected
I am using “micro ros” to run the microntroller (teensy 3.2)
Facing this issue only in jetson orin nano

Here is my environment information in jetson orin nano:
Package: nvidia-jetpack
Version: 5.1.2-b104
Architecture: arm64
Maintainer: NVIDIA Corporation
Installed-Size: 194
Depends: nvidia-jetpack-runtime (= 5.1.2-b104), nvidia-jetpack-dev (= 5.1.2-b104)
OS name: Ubuntu 20.04.6 LTS

The output is shown in the image attached:

Hi abdul.hannan,

Are you connecting a microcontroller with Orin Nano?
Could you share the block diagram of your connections?

Do you have other platform w/o hitting the issue?

Please also share the full dmesg for further check.

Please find the attached photo of how I am connecting to the microcontroller (teensy3.2)

Please note the issue again:
The microcontroller runs properly for the first time after being plugged, but if I stop the process and re-run the microcontroller it does not run but port /ttyACM0 is detected, I have re-plug it manually in again. I am running using “micro ros” to run which is a part of ROS 2 (foxy).

The other platform where I am not facing this issue is my laptop where I am using ROS 2’s (humble) “micro ros” package itself.

The below image highlights the issue, note that the entire process does not run (right-bottom) in the 2nd time and the ros 2 topics are not published (left-bottom) as well.
Note: the port: ttyACM0 is detected (left -bottom).

Do you connect Mirco-USB to Teensy3.2 and USB Type A to Jetson Orin Nano?
and you use Jetson Orin Nano as host to communicate with your Teesy3.2?

Is there error message showed in serial console log or dmesg?

Instead of running the application, have you tried to use echo and cat command on the interface(/dev/ttyACM0) at this moment?

Yes, the Micro-USB is connected to the teensy and USB-A is connected to jetson orin nano.

I am making a robot using ROS 2 (foxy) the role of teensy is to send IMU data (external sensor) to jetson orin nano and to send and receive motor position between jetson orin nano and teensy.

In jetson orin nano the controlling and viewing happens, due to this jetson orin nano is acting as master and teensy as slave.

Yes, there is output by running cat /ttyACM0 but if I start my process (micro ros) after running cat /ttyACM0 the issue is back i.e “micro ros” does not run entirely. Please note this is happening at the first time after being plugged in to jetson orin nano. photo is attached displaying the issue

I have discovered that if I use a C-type converter / cable attached to jetson orin nano’s C-type port I do not face any issue, I can run the microcontroller (teensy3.2) ample number of times without the need to re-plug manually.

The photo is attached of the connector/cable teensy and jetson orin nano

But what maybe the reason I face this issue in the USB-A ports of jetson orin nano ?

Does issue have to with the jetpack ?

Do you mean everything work as expected if you use TypeC port on the Orin Nano?

There should be several USB-A port on the Orin Nano devkit.
Do you hit the issue on every USB-A ports?
Or just specific port?

yes it woks as expected in the TypeC port of the Orin Nano

Yes I face the issue in all USB-A ports

TypeC port uses RHP.
TypeA port uses RTS5489 with hub.

Actually, we don’t have your MCU and program and even don’t know how they communicate with each other.

Could you try connect an external USB hub on TypeC port and then connect your USB cable to MCU and run your program?

Please run the following commands before test and provide the full dmesg when you hit the issue with USB-A port.

echo 'module usbcore +p' > /sys/kernel/debug/dynamic_debug/control
echo 'module xhci_hcd +p' > /sys/kernel/debug/dynamic_debug/control

Capture dmesg with the following command:

$ sudo dmesg -n 8

Regarding my code you can find it this link: GitHub - linorobot/linorobot2_hardware at foxy

It is serial communication I believe

Correction: I am using teensy 3.1

with the below setup I face the issue (same issue as mentioned in above conversation)

After running dmesg I got this long output but I believe that this part of the output is related to my port /ttyACM0

Please reboot the board and reproduce the issue.
After you hit the issue, please capture the dmesg with the following command.

$ sudo dmesg -n 8
$ sudo dmesg > dmesg.log

and share this dmesg.log as file here for further check.

After hitting the error this is the dmesg log file

dmesg.log (86.0 KB)

pardon for late reply

I don’t see there’re USB errors in dmesg.
However, there’re many EXT4-fs error (device mmcblk1p1).

Are you using SD card on the Orin Nano devkit?

Yes I am using only a SD card of 256GB

Could you share the result of the following command on your board?

$ cat /etc/nv_boot_control.conf

The result of the command cat /etc/nv_boot_control.conf is:

TNSPEC 3767-300-0005-K.2-1-0-jetson-orin-nano-devkit-
COMPATIBLE_SPEC 3767–0005–1–jetson-orin-nano-devkit-
TEGRA_OTA_BOOT_DEVICE /dev/mtdblock0
TEGRA_OTA_GPT_DEVICE /dev/mtdblock0

It seems you are using Orin Nano SKU5 on the devkit.

Could you use another SD card and use SDKM to re-flash the board?