This section tests the tutorial of Jetson nano serial port sending and receiving on its own.From the figure below, it can be seen that the TXD and RXD pins of the Jetson nano serial port correspond to physical pins 8 and 10, respectively.
Wiring:
Jetson NanoPin8(TXD)→Jetson Nano Pin10(RXD)
Enable the serial port permission. Please note that this permission will also be disabled after shutdown, and you need to restart it next time
sudo chmod 777 /dev/ttyTHS1
Download a serial communication case from Github, the source code and explanation can be viewed through this Github connection
xxxxxxxxxx
git clone <https://github.com/JetsonHacksNano/UARTDemo>
Enter folder
xxxxxxxxxx
cd UARTDemo
If you do not intend to use the serial console on UART, you should disable the serial console (it may not be a personal choice):
xxxxxxxxxx
systemctl stop nvgetty
systemctl disable nvgetty
udevadm trigger
Install the serial module
xxxxxxxxxx
sudo apt-get install python3-serial
Terminal input running program:
xxxxxxxxxx
sudo python3 uart_example.py
After running, you can see the characters in the "NVIDIA Jetson Nano Developer Kit" loop sent by Jetson nano and displayed on the terminal.
xxxxxxxxxx
sudo apt install cutecom
sudo cutecom
You can see that the cutecom is openGenerally, there is no need to set it up. Simply click on 'open' to use it, then input text through 'Input' and press' Enter 'to send the content.The effect is as shown in the picture:
If using a USB to TTL module for communication between a computer and a nano, please note the following points