Difference between revisions of "IoTGateway/BSP/Android/Gettingstarted/How to use UART for rk"
From ESS-WIKI
(Created page with "= <span style="color: rgb(0, 0, 205)">'''<span style="font-size: large">Overview</span>'''</span> = <span lang="en"><font color="#000000">The Android/Linux UART/serial port a...") |
|||
(5 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
+ | |||
= <span style="color: rgb(0, 0, 205)">'''<span style="font-size: large">Overview</span>'''</span> = | = <span style="color: rgb(0, 0, 205)">'''<span style="font-size: large">Overview</span>'''</span> = | ||
Line 5: | Line 6: | ||
== <span style="font-size: medium"><font color="#0066cc">RS-485</font></span> == | == <span style="font-size: medium"><font color="#0066cc">RS-485</font></span> == | ||
− | RS-485 uses half-duplex communication, which means that one medium is shared for transmitting and receiving data. Therefore the system needs to control the RS-485 transceiver's transmit mode. Usually the UART RTS signal is used to switch the transmitter on and off. | + | RS-485 uses half-duplex communication, which means that one medium is shared for transmitting and receiving data. Therefore the system needs to control the RS-485 transceiver's transmit mode. Usually the UART RTS signal is used to switch the transmitter on and off. |
− | |||
− | |||
− | |||
− | |||
= '''<span style="font-size: large"><span style="color: rgb(0, 0, 205)">Boards</span></span>''' = | = '''<span style="font-size: large"><span style="color: rgb(0, 0, 205)">Boards</span></span>''' = | ||
Line 15: | Line 12: | ||
== RSB4680 Borad == | == RSB4680 Borad == | ||
− | {| | + | {| align="left" border="1" cellpadding="1" cellspacing="1" style="width: 500px" |
|- | |- | ||
− | |||
− | |||
! scope="col" | | ! scope="col" | | ||
− | ''' | + | COM Name |
+ | |||
+ | (EPC-R4680) | ||
+ | |||
+ | ! scope="col" | | ||
+ | '''HW Schematic''' | ||
+ | |||
+ | '''(RSB-4680)''' | ||
+ | |||
+ | ! scope="col" | '''Device Node''' | ||
+ | ! scope="col" | | ||
+ | '''Remark''' | ||
|- | |- | ||
− | | | + | | style="text-align: center" | N/A |
− | | /dev/ | + | | style="text-align: center" | UART0 |
− | | | + | | style="text-align: center" | /dev/ttyS0 |
+ | | for BT Data | ||
|- | |- | ||
− | | | + | | style="text-align: center" | COM5 |
− | | /dev/ | + | | style="text-align: center" | COM1 |
− | | | + | | style="text-align: center" | /dev/ttyS1 |
+ | | RS232 | ||
|- | |- | ||
− | | | + | | style="text-align: center" | COM1 |
− | | | + | | style="text-align: center" | COM2 |
− | | | + | | style="text-align: center" | /dev/ttyS2 |
+ | | Debug Port/RS232 | ||
|- | |- | ||
− | | | + | | style="text-align: center" | COM6 |
− | | | + | | style="text-align: center" | COM3 |
− | | | + | | style="text-align: center" | /dev/ttyS3 |
+ | | RS232 | ||
|- | |- | ||
− | | | + | | style="text-align: center" | COM2 |
− | | | + | | style="text-align: center" | COM4 |
− | | | + | | style="text-align: center" | /dev/ttyS4 |
+ | | Supprot RSB485 | ||
|- | |- | ||
− | | COM6 | + | | style="text-align: center" | COM3 |
− | | | + | | style="text-align: center" | COM6 |
− | | | + | | style="text-align: center" | /dev/ttyUSB0 |
+ | | Usb to Uart | ||
+ | |- | ||
+ | | style="text-align: center" | COM4 | ||
+ | | style="text-align: center" | COM7 | ||
+ | | style="text-align: center" | /dev/ttyUSB1 | ||
+ | | Usb to Uart | ||
|} | |} | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
| | ||
− | [[File: | + | [[File:RS232andRS485Jumper.PNG|RTENOTITLE]] |
Latest revision as of 11:11, 11 June 2024
Contents
Overview
The Android/Linux UART/serial port access from user is through the tty-devices. The tty-devices have different names depending on UART driver on different board.
RS-485
RS-485 uses half-duplex communication, which means that one medium is shared for transmitting and receiving data. Therefore the system needs to control the RS-485 transceiver's transmit mode. Usually the UART RTS signal is used to switch the transmitter on and off.
Boards
RSB4680 Borad
COM Name (EPC-R4680) |
HW Schematic (RSB-4680) |
Device Node |
Remark |
---|---|---|---|
N/A | UART0 | /dev/ttyS0 | for BT Data |
COM5 | COM1 | /dev/ttyS1 | RS232 |
COM1 | COM2 | /dev/ttyS2 | Debug Port/RS232 |
COM6 | COM3 | /dev/ttyS3 | RS232 |
COM2 | COM4 | /dev/ttyS4 | Supprot RSB485 |
COM3 | COM6 | /dev/ttyUSB0 | Usb to Uart |
COM4 | COM7 | /dev/ttyUSB1 | Usb to Uart |