[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] efficiency of assigning bits
From: |
Daniel O'Connor |
Subject: |
Re: [avr-gcc-list] efficiency of assigning bits |
Date: |
Mon, 14 Mar 2005 11:24:40 +1030 |
User-agent: |
KMail/1.7.92 |
On Mon, 14 Mar 2005 03:03, Parthasaradhi Nayani wrote:
> > Wouldn't it be a better idea to write code that
> > compiles with avr-gcc?
> > $ avr-gcc -mmcu=at90s2313 /tmp/nayani.c
> > /tmp/nayani.c:4:14: invalid suffix "B11101101"
> > on integer constant
>
> winavr is avr-gcc. The suffix error - you have not
> preceded the 'B' with a zero so naturally the compiler
> complained.
>
> The correct method is 0Bxxxxxxxx
>
> Also please the binary suffix is implemented in the
> recent past (gcc). Please check the version you have.
I'd be more inclined to use hexidecimal since it's considerably more widely
supported though.
(Also converting binary -> hex is fairly easy in your head)
--
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
-- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C
pgp2WJFwfD688.pgp
Description: PGP signature
- Re: [avr-gcc-list] efficiency of assigning bits, (continued)
- Re: [avr-gcc-list] efficiency of assigning bits,
Daniel O'Connor <=
Re: [avr-gcc-list] efficiency of assigning bits, Parthasaradhi Nayani, 2005/03/13
Re: [avr-gcc-list] efficiency of assigning bits, Parthasaradhi Nayani, 2005/03/13
Re: [avr-gcc-list] efficiency of assigning bits, Jamie Morken, 2005/03/14