When receiving data using the ttyTHS0 serial port, there is a delay in receiving data

Hello, everyone!
When input-output self-testing of serial port data using Jetson NX, there is an acceptance delay and the character PASSWORD is received.
During the serial port data transmission between the computer and the development board, the computer cannot accept the data sent by the development board. The development board can receive the data sent by the computer, but it cannot receive the first three characters sent by the development board.
I would like to ask how to set up, can realize the real-time transmission of data through serial communication, and will not cause the loss of data.

hello chen_xi0915,

the default baud-rate settings is 115200/8n1,
are you having the same configure for UART communication.

The configuration is the same, also 115200/8n1.
I wonder if ttyTHS0 is tied to Ubuntu’s serial login.

hello chen_xi0915,

Jetson Xavier NX brings three UARTs out to the main connector,
please check [Figure 11-5. Jetson Xavier NX UART Connections] from Jetson Xavier NX Product Design Guide for reference,
you may also check $ dmesg | grep THS, for the actual serial port you’re using.

I use UART1_TXD and UART1_RXD, two general serial ports for communication, but I still receive the character “PASSWORD” when receiving data, and there is still a delay in receiving data. Could you please tell me the reason or how to do so as to receive data in real time?

The pin 8/10 serial UART is for serial console. Note that if you run this command:
ls -l /dev/ttyUSB* /dev/ttyACM* /dev/ttyS*
…then most will have group “dialout” in the permissions.

However, one might have group “tty”. I would expect this for the pin 8/10 UART. This is because serial console is running. Typically one would turn off serial console (at least in Linux, but there is more to the store in boot stages prior to Linux running) via:
sudo systemctl disable nvgetty.service

Do note that serial devices of naming convention “/dev/ttyS#” will be using a traditional serial UART driver, while serial devices of naming convention “/dev/ttyTHS#” will be using NVIDIA’s “Tegra High Speed” driver. Mostly the port for a given physical UART can run either of those drivers, and depending on which driver is involved, then the “/dev” file name changes. Both ttyTHS0 and ttyS0 are the same UART, but different drivers. You don’t want to use both at once as results are undefined. Is ttyS0 group “tty”? If so, then “ttyTHS0” is already in use, and the disable of nvgetty.service should help once boot stages are complete.

1 Like