# G720 Android 14 UART loopback test

**URL:** <https://genio-community.mediatek.com/t/g720-android-14-uart-loopback-test/3454>\
**Category:** General Discussion\
**Tags:** Android\
**Created:** [November 2, 2026, 3:29am UTC](https://genio-community.mediatek.com/t/g720-android-14-uart-loopback-test/3454 "2026-11-02T03:29:34Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Josh\_Tang](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@Josh\_Tang](https://genio-community.mediatek.com/u/Josh_Tang)\
**Post date:** [November 2, 2026, 3:29am UTC](https://genio-community.mediatek.com/t/g720-android-14-uart-loopback-test/3454/1 "2026-11-02T03:29:34Z")

</div>

How can I quickly perform a UART2/UART3 TXD/RXD loopback test on a G720 Android 14 device without any external UART devices connected?

aiot8391p2\_64\_bsp:/ # ls /sys/bus/platform/devices/11004000.serial/tty/

ttyS3

aiot8391p2\_64\_bsp:/ # ls /sys/bus/platform/devices/11003000.serial/tty/

ttyS2

---

<div class="post-metadata">

**Author:** ![chris.chen](https://avatars.discourse-cdn.com/v4/letter/c/8edcca/32.png) [@chris.chen](https://genio-community.mediatek.com/u/chris.chen)\
**Post date:** [November 3, 2026, 11:12pm UTC](https://genio-community.mediatek.com/t/g720-android-14-uart-loopback-test/3454/5 "2026-11-03T23:12:45Z")

</div>

Hi Josh,

ttyS2 (11003000.serial) and ttyS3 (11004000.serial) are already registered by  
the 8250-based UART driver, so you can test them in either of two ways:

1. Internal loopback (no wiring)  
Configure the port with termios (raw mode, baud rate, no flow control), then  
set the TIOCM\_LOOP modem-control bit via ioctl(fd, TIOCMBIS, …) to enable  
the UART’s loopback mode. Anything you write() should then be read() back.  
Note this only checks the controller/driver, not the pinmux or the board pins.

2. External loopback  
Short TXD to RXD of the same UART on the header, then open the tty  
(e.g. stty -F /dev/ttyS2 115200 raw -echo -crtscts), write data and read it back.  
This also verifies the pins and wiring.

Please make sure no other service is holding the port. If it still fails, share  
your BSP/kernel version and the output of `dmesg | grep -i serial`.
