avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] USART - Interrupt - problem (SOLVED)


From: Onno van Eijk
Subject: Re: [avr-gcc-list] USART - Interrupt - problem (SOLVED)
Date: Sun, 23 May 2004 12:04:32 +0200

On Sat, 2004-05-22 at 23:26, Theodore A. Roth wrote:

> > #include <avr/io.h>
> > #include <avr/signal.h>
> > #include <avr/interrupt.h>
> >
> > SIGNAL(SIG_USART_RECV)
> 
> The mega32 header defines this:
> 
>   #define SIG_UART_RECV           _VECTOR(13)
> 
> Fix that and you should get things working.
> 
Thanks you are right, this solved the problem. I did wonder which signal
to choose. When the compilere did no protest, I assumed I had the right
one. Now I understand where to find them, so in the future I can make
sure, I have the right one.

> > {
> >     while ( !(UCSRA & (1 << RXC) ) );
> 
> I don't think you need this while loop.
> 
Indeed. It works with and without the while loop. I removed it, as it is
not required.

Thanks for responding so quickly.

grz,
Onno



reply via email to

[Prev in Thread] Current Thread [Next in Thread]