--- In lpc2000@yahoogroups.com, "ian.scanlon" <scanlon.design@...> wrote:
>
> Does writing directly to the uart tx register work? How about putc ?
>
writing directly works very well as long as you do not overfill the
fifo's.
here is some code I wrote earlier ;)
typedef union
{
unsigned long whole;
unsigned char part_byte[4];
} four_bytes;
void UNDEF_Routine(void)
{
register unsigned int *lr_ptr asm("r14");
four_bytes temp;
temp.whole = (usigned long) lr_ptr;
UART0_THR = temp.part_byte[3];
UART0_THR = temp.part_byte[2];
UART0_THR = temp.part_byte[1];
UART0_THR = temp.part_byte[0];
}
By the way thanks to the guys who helped me with reading the Link
Regitser.Message
Re: UART0 and Printf
2006-04-24 by fordp2002
Attachments
- No local attachments were found for this message.