cancel
Showing results for 
Search instead for 
Did you mean: 

UART1 as half-duplex

selenau
Associate II
Posted on November 18, 2005 at 13:17

UART1 as half-duplex

3 REPLIES 3
selenau
Associate II
Posted on November 18, 2005 at 06:05

I'm trying to use UART1 as half-duplex. It looks ok, but I'm receiving back the last 3 chars everytime i try to send something.

any clue?

GPIO_Config(GPIO0, SMARTCARD_DATAIN_OUT, GPIO_AF_PP);

UART_OnOffConfig(UART1, ENABLE); // Turn UARTX on

UART_FifoConfig (UART1, DISABLE); // Disable FIFOs

UART_FifoReset(UART1, UART_RxFIFO); // Reset the UART_RxFIFO

UART_FifoReset(UART1, UART_TxFIFO); // Reset the UART_TxFIFO

UART_LoopBackConfig(UART1, DISABLE); // Disable Loop Back

// Configure the UARTX as following: - Baudrate = 9600 Bps Odd parity 8 data bits + 1 byte Parity 1.5 stop bit

UART_Config(UART1, 9600, UART_EVEN_PARITY, UART_1_5_StopBits, UARTM_8D_P);

UART_RxConfig(UART1, ENABLE); //Enable Rx

UART_ItConfig(UART1, UART_RxBufFull, ENABLE);

EIC_IRQChannelPriorityConfig(UART1_IRQChannel, 2);// Configure the EIC channel interrupt

EIC_IRQChannelConfig(UART1_IRQChannel, ENABLE);// Enable UART1 IRQ Interrupts

selenau
Associate II
Posted on November 18, 2005 at 08:46

I just want to use one pin (p0.10). Why should I need to configure p0.11, too?

selenau
Associate II
Posted on November 18, 2005 at 13:17

also still not working, too.