avr-libc-dev
[Top][All Lists]
Advanced

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

Re: [avr-libc-dev] [Bug #2633] syntax error while setting up sleep mode


From: Theodore A. Roth
Subject: Re: [avr-libc-dev] [Bug #2633] syntax error while setting up sleep mode functionality
Date: Fri, 21 Feb 2003 11:32:12 -0800 (PST)


:) Summary:  syntax error while setting up sleep mode functionality
:)
:) Original Submission:  When using WinAVR release 20030115, this code:
:)
:)   set_sleep_mode(SLEEP_MODE_IDLE);
:)
:) returns parse error when -mmcpu=atmega8, this code:
:)
:)   set_sleep_mode(SLEEP_MODE_IDLE));
:)
:) does not (I have no idea how MCU-specific this error is, I haven't 
investigated further).

I can't reproduce this with the following program:


#include <avr/sleep.h>

int main (void)
{
    set_sleep_mode(SLEEP_MODE_IDLE);

    while (1);

    return 0;
}


Here's my build output:

address@hidden:~/test$ make
avr-gcc -g -O2 -Wall -mmcu=atmega8   -c -o test.o test.c
avr-gcc -g -O2 -Wall -mmcu=atmega8 -Wl,-Map,test.map -o test test.o
cp test test.elf
avr-objdump -h -S -D --disassemble-zeroes test.elf > test.lst
avr-objcopy -O ihex test.elf test.hex
avr-objcopy -O binary test.elf test.bin
avr-objcopy -O srec test.elf test.srec


Can you send me you test app?
Do you #include <avr/sleep.h> ?


Ted Roth




reply via email to

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