i want to control uart rts pin manually, set high and low by my program.
I'm using uart1 AM335x. in my program:
UART1_RTS_PINMUX = MODE4;
(UART1_BaseAddr + UART_MCR) |= (1 << 1); //clear rts
delay_1s(); //delay 1 second
(UART1_BaseAddr + UART_MCR) &= ~(1 << 1); //set rts
delay_1s(); //delay 1 second
when i measure the UART1 RTS pin, it keep pulling low, 0V.
how i can control the UART RTS pin manually by code?
do i miss-configure something in my program?
Thanks and Regards
Need few infor before suggesting.
1. Which Board?
2. Is the pin-mux properly set for this pin
3. Is Total number of available pins are short in case of AM335x, Pins are mux'ed between different modules and are available only in depending on few criteria (like Profile in case of EVM, ON daughter board in case of BeagleBone ...)
Does this help with your question? If not, please send back more information. If it answers your question, please click the Verify Answer button.
I forgot to mention. On EVM, UART1 pins are not available on DB9 connector. They are used by Bluetooth Module
i use my custom board. The UART1 tx, rx, cts, rts, are connected to RS232 transceiver, and to DB9 connector. I'm using PSP04.06.00.07, you mention about bluetooth module, do i need to disable the bluetooth module before using UART ?
Actually i want to use Full Modem of RS232, i need include hardware flow control and software flow control in my design. But seem like linux serial driver not supported, that why i need to manually trigger the control line of RS232.
UART1: tx, rx , cts, rts pin mux select is mode 0
UART1: ri, dcd , dsr, dtr pin mux select is mode 4
is there any better idea rather than trigger the line manually?
1. in 07 release code, Bluetooth module uses uart1 port. Disable Bluetooth init function from board-am335x.c (mmc2_wl12xx_init, uart1_wl12xx_init & wl12xx_init)
2. Linux supports UART flow control. use stty command to enable hw flow control.
i use command "stty -F /dev/ttyO1 crtscts" to enable RTS/CTS hardware flow control, UART1 still can sending out data athough the CTS line not asserted by a RS232 device, no matter what hardware flow control setting i use on the RS232 device, let say DTR/DSR flow control, the UART1 still transmit data sucessfully. seem like UART1 dont care the RTS, CTS, DTR, DSR lines.
Plus, do linux have prepare an option to enable DTR/DSR flow control by command stty?
some linux forum said linux not support DTR/DSR flow control, is it true?
after i go through the AM335x TRM, there is no configuration for DTR/DSR, only have RTS/CTS and Ixon/ixoff flow control.
We are experiencing the very same problem.
Custom board w/ Beaglebone as guide. Added standard, non-bluetooth UART1 pinmux to kernel init. Set app code and minicom terminal with hardware flow control and communication is fine, but no evidence of activity with a scope on the RTS/CTS lines. The other processor in or system needs hardware flow control lines to be active.
Have you received any info or did you find a solution?
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.