Khadas Docs

Amazing Khadas, always amazes you!

User Tools

Site Tools


Sidebar

products:sbc:common:applications:gpio:uart

This is an old revision of the document!


UART

Introduction

This document mainly introduces the usage of UART on 40-Pin Header.

UART Information

UART PIN & GPIO(#Number) DT Overlays Node Device Node
VIM1/2 UART_AO_B RX(15) - GPIOAO_5(#506)
TX(16) - GPIOAO_4(#505)
uart4 /dev/ttyS4
VIM3/3L UART_C RX(15) - GPIOH_6(#433)
TX(16) - GPIOH_7(#434)
uart3 /dev/ttyS3
VIM4 UART_E RX(15) - GPIOY_7(#491)
TX(16) - GPIOY_6(#490)
uart_e /dev/ttyS4

Enable UART

Uart PIN in 40-Pin Header is PIN15 and PIN16. Refer to Device Tree Overlay.

Enable uart node via device tree overlays. Edit /boot/env.txt to add uartX to overlays. E.g.

overlays=uart4 pwm_ao_a pwm_f i2c0

Reboot to effect.

  • VIM1/VIM2/VIM4 - uar4
  • VIM3/VIM3L - uart3

Check UART Node

After reboot, you will see the uart device node.

  • VIM1/VIM2/VIM4 - /dev/ttyS4
  • VIM3/VIM3L - /dev/ttyS3
Last modified: 2022/07/12 23:02 by nick