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

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

Re: [avr-gcc-list] sleep mode error on SM bit


From: Joerg Wunsch
Subject: Re: [avr-gcc-list] sleep mode error on SM bit
Date: Wed, 25 Jun 2003 16:27:28 +0200 (MET DST)

"Ezio Balbo" <address@hidden> wrote:

> This is the copiler output from the linux pc:
> 
> /*
> avr-g++ -g -Wall -fno-exceptions -Os -mmcu=at90s8515    -c -o main.o main.c
> main.c: In function `void shutdown()':
> main.c:323: error: `SM0' undeclared (first use this function)
> main.c:323: error: (Each undeclared identifier is reported only once for
> each
>    function it appears in.)
> main.c:323: error: `SM1' undeclared (first use this function)
> main.c:323: error: `SM2' undeclared (first use this function)

That looks fairly bogus.

Please run

avr-g++ -g -Wall -fno-exceptions -Os -mmcu=at90s8515    -E main.c

and lookup what the preprocessor makes out of all this.  I can't see
how the above could happen with either rev 1.5 or 1.6 of avr/sleep.h.
Both first test whether SM0/SM1/SM2 are defined, and if they aren't,
the logic to use SLEEP_TYPE 1 should work.
-- 
J"org Wunsch                                           Unix support engineer
address@hidden        http://www.interface-systems.de/~j/


reply via email to

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