RE: [avr-gcc-list] Options on avr-gcc

2007-02-12 Thread larry barello
Declaring N as volatile is a good solution. The alternative is to disenable optimization on GCC (-o0) but I don't think you will like the results. Another solution is to put asm(nop); In your loop body. That will force the compiler to implement the loop. There might be some fancier

Re: [avr-gcc-list] Options on avr-gcc

2007-02-12 Thread Joerg Wunsch
Javier Almansa Sobrino [EMAIL PROTECTED] wrote: Any one knows what option I must to pass to AVR-GCC when compile to avoid this. The best option is to don't try rolling your own loops at all. Instead, use the functions from util/delay.h. There are two functions (with a different argument