This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP430 UART with RTS/CTS

Other Parts Discussed in Thread: MSP-EXP430F5529LP

Dear all,

I want to add RTS/CTS on the simpleUsbBackchannel example of MSP-EXP430F5529LP. I want to use RTS in P6.7 and CTS in P1.7.

I've add the definition,

	P6DIR |= BIT7;	//KJ: EAP_RX_ACK_CONFIG();
	P6OUT |= BIT7;	//KJ: EAP_RX_ACK_SET();

	P1DIR &= ~BIT7;	//KJ: EAP_TX_ACK_CONFIG();
	P1IES |= BIT7;	//KJ: EAP_TX_ACK_CONFIG();
	P1IFG &= ~BIT7;	//KJ: EAP_TX_ACK_CONFIG();
	P1IE |= BIT7;	//KJ: EAP_TX_ACK_CONFIG();

and interrupt

#pragma vector=PORT1_VECTOR	//KJ: EAP_TX_ACK_VECTOR
__interrupt void txAckIsr(void)
{
    if (P1IFG & BIT7)	//KJ: EAP_TX_ACK_TST()
	{
    	// Look for received bytes over USB. If any, send over backchannel UART.
    	rxByteCount = cdcReceiveDataInBuffer(buf_usbToBcuart, sizeof(buf_usbToBcuart), CDC0_INTFNUM);
    	if(rxByteCount)
    	{
    		bcUartSend(buf_usbToBcuart, rxByteCount);
    	}
    }
    __bic_SR_register_on_exit(LPM3_bits);	//KJ: WAKEUP();
}

in BCUart.c.

And I marked the trans from USB to UART in main.c

/*
       // Look for received bytes over USB. If any, send over backchannel UART.
       rxByteCount = cdcReceiveDataInBuffer(buf_usbToBcuart, sizeof(buf_usbToBcuart), CDC0_INTFNUM);
       //rxByteCount = hidReceiveDataInBuffer(buf_usbToBcuart, sizeof(buf_usbToBcuart), HID0_INTFNUM);
       if(rxByteCount)
       {
           bcUartSend(buf_usbToBcuart, rxByteCount);
       }
*/

But I just can send text from UART to USB, can someone help me?

Thanks.

B.R.

KJ

**Attention** This is a public forum