This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Can send serial data but not receive

When I try to use getchar, the program just hangs. It seems as though the bit in the U0LSR register that says data is in the RDR register is not being set.

printf works just fine as I can see everything I need to see in hyperterminal. So I know data is being transmitted, I'm just not sure if data is being received.
Heres the modified getchar function.

int getchar (void)
{              /* Read character from Serial Port   */

  while (!(UART0_LSR & 0x01));

  return (UART0_RBR);
}

0