Skip to content

Serial Devices

USB TO 4CH TTL

Preparation

  • Rhino Pi-X1
  • USB TO 4CH TTL serial device
  • CH340 USB TO TTL test board
  • Several Dupont wires
  • Windows computer

Hardware Connection

  • Connect the development board to the CH344 device via the USB interface.
  • Connect the CH340 test board to the USB port of a Windows computer and the CH344 device.

alt text

Note: Connect RXD, TXD, and GND of CH344 to TXD, RXD, and GND of CH340 respectively.

Testing

💡Note

When executing commands in the terminal of the AidLux desktop, if you need to enter the aidlux password, input: aidlux

  1. After obtaining the IP address of the Rhino Pi-X1 development board, log in to the AidLux Web desktop via a browser. For detailed login methods, refer to Web Login in the Hardware Guide.

  2. After logging in, enter the following command in the AidLux terminal to check if the CH344 serial device is recognized:

shell
ls -l /dev/ttyCH*

alt text

💡Note

The multi-channel serial device names of CH344 correspond one-to-one with the actual physical UART interface names: /dev/ttyCH343USB0 corresponds to UART0; /dev/ttyCH343USB1 corresponds to UART1, and so on.

  1. Install the minicom tool

minicom is not installed by default in AidLux; install it using the following commands:

shell
sudo apt update
sudo apt install minicom
  1. Open the serial device on Rhino Pi-X1 using the minicom tool

If the uart0 port of the connected CH344 is used, execute the following command to open the serial device:

shell
sudo minicom -D /dev/ttyCH343USB0 -b 115200
  1. Open the "Serial Port Debug Tool" on the Windows computer, and select the corresponding serial port and set the baud rate (keep it consistent with the settings in the AidLux terminal).

alt text

  1. After configuring both the "Serial Port Debug Tool" on Windows and the terminal on AidLux, you can perform message sending and receiving tests.

alt text

💡Note

If a permission error is prompted, execute the command: sudo su to switch to the root user, then re-run the test (enter the password: aidlux). To enable input character display in minicom, press the following keys in sequence: Ctrl+A Z E.

alt text

USB TO 8CH TTL

Preparation

  • Rhino Pi-X1
  • USB TO 8CH TTL serial device
  • CH340 USB TO TTL test board
  • Several Dupont wires
  • Windows computer

Hardware Connection

  • Connect the development board to the CH348 device via the USB interface; connect the CH340 test board to the USB port of a Windows computer and the CH348 device.

Note: Connect RXD, TXD, and GND of CH348 to TXD, RXD, and GND of CH340 respectively.

alt text

Testing

💡Note

When executing commands in the terminal of the AidLux desktop, if you need to enter the AidLux password, input: aidlux

  1. After obtaining the IP address of the Rhino Pi-X1 development board, log in to the AidLux Web desktop via a browser. For detailed login methods, refer to Web Login in the Hardware Guide.

  2. After logging in, enter the following command in the AidLux terminal to check if the CH348 serial device is recognized:

shell
ls -lh /dev/ttyCH*

alt text

💡Note

The multi-channel serial device names of CH348 correspond one-to-one with the actual physical UART interface names: /dev/ttyCH9344USB0 corresponds to UART0; /dev/ttyCH9344USB1 corresponds to UART1, and so on.

  1. Install the minicom tool

minicom is not installed by default in AidLux; install it using the following commands:

shell
sudo apt update
sudo apt install minicom
  1. Open the serial device on Rhino Pi-X1 using the minicom tool

If the uart0 port of the connected CH348 is used, execute the following command to open the serial device:

shell
sudo minicom -D /dev/ttyCH9344USB0 -b 115200
  1. Open the serial device using a serial port debug tool on Windows

Install a serial port debug tool on Windows. After opening the tool, select the corresponding port and open it. Note: The baud rate must be consistent with that set by the minicom tool on Rhino Pi-X1 (e.g., 115200).

  1. Perform mutual message sending tests on both ends

You can enter any characters in minicom for sending tests, and the serial port debug tool on Windows will receive the messages; vice versa.

Tip

minicom does not print input characters by default. Press Ctrl-A Z E in sequence to enable input character display.

alt text

CH9102

Preparation

  • Rhino Pi-X1
  • CH9102 serial device
  • CH340 USB TO TTL test board
  • Several Dupont wires
  • Windows computer

Hardware Connection

  • Connect the development board to the CH9102 device via the USB interface; connect the CH340 test board to the USB port of a Windows computer and the CH9102 device.

Note: Connect RXD, TXD, and GND of CH9102 to TXD, RXD, and GND of CH340 respectively.

alt text

Testing

💡Note

When executing commands in the terminal of the AidLux desktop, if you need to enter the AidLux password, input: aidlux

  1. After obtaining the IP address of the Rhino Pi-X1 development board, log in to the AidLux Web desktop via a browser. For detailed login methods, refer to Web Login in the Hardware Guide.

  2. After logging in, enter the following command in the AidLux terminal to check if the CH9102 serial device is recognized:

shell
ls -l /dev/ttyC*

alt text

  1. Configure the serial device number using the stty tool
shell
chmod 777 /dev/ttyCH343USB0                              //Assign permissions to the serial device number
stty -F /dev/ttyCH343USB0 115200                         //Set the baud rate of the serial device number
stty -F /dev/ttyCH343USB0 -isig -icanon iexten -echo     //Additional settings
  1. Open the serial device using a serial port debug tool on Windows

Install a serial port debug tool on Windows. After opening the tool, select the corresponding port and open it. Note: The baud rate must be consistent with that set by the stty tool on Rhino Pi-X1 (e.g., 115200).

  1. Perform mutual message sending tests on both ends

You can send characters to the serial device number using the echo command, and observe that the serial tool on Windows receives the messages; vice versa, send characters via the serial tool on Windows, and receive them on Rhino Pi-X1 using the cat command.

Sending command:

shell
echo '8550-to-windows' > /dev/ttyCH343USB0

Receiving command:

shell
cat /dev/ttyCH343USB0

alt text

CP2102

  • Official Kit Documentation: CP2102

Preparation

  • Rhino Pi-X1
  • CP2102 serial device
  • CH340 USB TO TTL test board
  • Several Dupont wires
  • Windows computer

Hardware Connection

  • Connect the development board to the CP2102 device via the USB interface; connect the CH340 test board to the USB port of a Windows computer and the CP2102 device.

Note: Connect RXD, TXD, and GND of CP2102 to TXD, RXD, and GND of CH340 respectively.

alt text

Testing

💡Note

When executing commands in the terminal of the AidLux desktop, if you need to enter the AidLux password, input: aidlux

  1. After obtaining the IP address of the Rhino Pi-X1 development board, log in to the AidLux Web desktop via a browser. For detailed login methods, refer to Web Login in the Hardware Guide.

  2. After logging in, enter the following command in the AidLux terminal to check if the CP2102 serial device is recognized:

shell
ls -l /dev/ttyU*

alt text

  1. Configure the serial device number using the stty tool
shell
chmod 777 /dev/ttyUSB0                              //Assign permissions to the serial device number
stty -F /dev/ttyUSB0 115200                         //Set the baud rate of the serial device number
stty -F /dev/ttyUSB0 -isig -icanon iexten -echo     //Additional settings
  1. Open the serial device using a serial port debug tool on Windows

Install a serial port debug tool on Windows. After opening the tool, select the corresponding port and open it. Note: The baud rate must be consistent with that set by the stty tool on Rhino Pi-X1 (e.g., 115200).

  1. Perform mutual message sending tests on both ends

You can send characters to the serial device number using the echo command, and observe that the serial tool on Windows receives the messages; vice versa, send characters via the serial tool on Windows, and receive them on Rhino Pi-X1 using the cat command.

Sending command:

shell
echo '8550-to-windows' > /dev/ttyUSB0

Receiving command:

shell
cat /dev/ttyUSB0

alt text