avr-chat
[Top][All Lists]
Advanced

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

RE: [avr-chat] SFRs in assembly code


From: Weddington, Eric
Subject: RE: [avr-chat] SFRs in assembly code
Date: Wed, 22 Jul 2009 16:00:46 -0600

 

> -----Original Message-----
> From: address@hidden 
> [mailto:address@hidden
>  On Behalf Of Daniel Otte
> Sent: Wednesday, July 22, 2009 3:51 PM
> To: address@hidden
> Subject: Re: [avr-chat] SFRs in assembly code
> 
> Hi,
> I investigated a little bit more and included the definition 
> of UBRR_VALUE into
> my code-file.
> It seems that the preprocessor of gas doesn't handle the UL 
> suffix correct.
> 
> #define UBRR_VALUE  ((((F_CPU) + (8 * (BAUD)))/ (16 * (BAUD))) -1)
> 
> works, while
> 
> #define UBRR_VALUE ((((F_CPU) + (8UL * (BAUD))) /(16UL * 
> (BAUD))) -1UL)

First off, where is this definition of UBRR_VALUE coming from? Somehow -1 and 
UL should not go together (an *unsigned* long -1??).
 




reply via email to

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