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

Serial communicaion Problem Simulayion is working but not in hw

#include <LPC21xx.H>
void uart0_init()
{

PINSEL0 = 0x00000005; U0LCR = 0x83; U0DLL = 97; U0LCR = 0x03;
}

void uart0_putc(char c)
{ while(!(U0LSR & 0x20)); U0THR = c;
}

void uart0_puts(char *p)
{ while(*p) { uart0_putc(*p++); }
}

int main (void)
{ uart0_init();
while (1) {
uart0_puts ("s");
} }

Parents Reply Children
No data