How to verification the uart's RTS/CTS can work use KW41Z on MCUXpresso?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to verification the uart's RTS/CTS can work use KW41Z on MCUXpresso?

1,197 Views
danieltseng
Contributor V

KW41Z's SDK_2.2_FRDM-KW41Z which has example and driver .
Uart only supported by the software program TX / RX, and does not support the CTS/RTS function.
I needs to verify that the CTS/RTS on the hardware is working properly.
I found the simplest uart program (lpuart --> polling).
To ask how to modify the UART can be verified CTS and RTS hardware wiring can work properly?

【   frdmkw41z_driver_examples_lpuart_polling 】

SW modifications:

board/pin_mux.c

void BOARD_InitLPUART(void) {

   CLOCK_EnableClock(kCLOCK_PortC);                          

   PORT_SetPinMux(PORTC, PIN4_IDX, kPORT_MuxAlt4);      /* PORTC4 (pin 40) is  UART0_RTS PTC4 */

  PORT_SetPinMux(PORTC, PIN5_IDX, kPORT_MuxAlt4);       /* PORTC5 (pin 41) is  UART0_CTS PTC5 */

  PORT_SetPinMux(PORTC, PIN6_IDX, kPORT_MuxAlt4);       /* PORTC6 (pin 42) is UART0_RX */

  PORT_SetPinMux(PORTC, PIN7_IDX, kPORT_MuxAlt4);       /* PORTC7 (pin 43) is UART0_TX */

Labels (1)
0 Kudos
Reply
1 Reply

939 Views
gerardo_rodriguez
NXP Employee
NXP Employee

Hello Daniel,

 

As you noticed, hardware flow control is not supported in the KSDK 2.2 drivers for the LPUART. However, this will be supported on the next version of the KSDK.

The hardware flow control in the LPUART module is configured through the LPUARTx_MODIR register. Please refer to chapter 38.2.6 LPUART Modem IrDA Register in the reference manual for information on this functionality.
 
Regards,
Gerardo

0 Kudos
Reply