Reputation: 21
I want to use RTS
pin
of UART1
to communicate through RS 485
protocol.
I have enabled UART1
through
/media/BEAGLEBONE/uEnv.txt
optargs=quiet drm.debug=7 capemgr.enable_partno=BB-UART1
Device tree overlay snippet:
0x180 0x20 /* uart1_rxd | MODE0 */
0x184 0x20 /* uart1_txd | MODE0 */
0x17c 0x00 /* uart1_rts | MODE0 */
0x178 0x00 /* uart1_cts | MODE0 */
cat /proc/tty/driver/OMAP-SERIAL
serinfo:1.0 driver revision:
0: uart:OMAP UART0 mmio:0x44E09000 irq:72 tx:2818 rx:100 RTS|CTS|DTR|DSR
1: uart:OMAP UART1 mmio:0x48022000 irq:73 tx:0 rx:0 CTS|DSR|CD|RI
How to enable RTS pin
on P9.19
by selecting mode 0
?
Upvotes: 2
Views: 4426
Reputation: 11
The muxing mode of the pins both set to same mode. Change it to:
0x180 0x20 /* UART1_RXD, INPUT | MODE0 */
0x184 0x00 /* UART1_TXD, OUTPUT | MODE0 */
0x17c 0x00 /*UART1_RTS*/
0x178 0x20 /*UART1_CTS*/
To use the RTS pin send the pin number from the overlay.
rts-gpio = <&gpio0 13 0>
Upvotes: 1