AnsweredAssumed Answered

UART Echo on BF527

Question asked by savinat on Feb 24, 2010
Latest reply on Feb 24, 2010 by Andreas

Hi to all

I want to implement an Echo UART on BF 527. I want to recieve data and then when the recieve is complete to generate an interrupt (*pUART1_IER = ERBFI ) Is there any function like interrupts(); Can i write this: interrupt(SIGIVG7, UART1_Isr);

and in the function UART1_ISR is this:

void UART1_Isr(void)
    int nStatus = 0;       
    int value;

value = *pUART1_RBR;

// echoes back the value

     if( (*pUART1_LSR & THRE) )
                *pUART1_THR = value;
                nStatus = 1;
  // poll to ensure UART has completed the transfer
  while ((*pUART1_LSR & TTEMT) == 0)


Do i have to perform a function for recieving data and how the UART knows that has to recieve  - do i ahev to enable recieve mode in some register?