[Top][All Lists]

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

[avr-libc-dev] [bug #32551] util/delay.h delays longer than they should

From: Anitha Boyapati
Subject: [avr-libc-dev] [bug #32551] util/delay.h delays longer than they should be
Date: Mon, 21 Feb 2011 07:00:08 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20101203 Firefox/3.6.13

Follow-up Comment #2, bug #32551 (project avr-libc):

Frank Zhao:


An example of the problem is demonstrated by this forum post as well


I have seen bug 30363 but it seems unrelated


Something sounds very contradictory here.  Your comment says the delay is 4
times longer while the thread talks about delay being 4 times less. If the
problem is related to the topic discussed in thread, then it is exactly
referring to bug30363. 

The output is 4 less because previous version of avr-libc ( < 1.7.0) used some
algorithm where iterating through a loop takes 4 cpu cycles. The idea is to
iterate through the loop delay/4 times so that required delay is achieved.

However in 1.7.0, the loop has been replaced with builtins which provide exact
number of delay cycles. However the same parameter which was sent to the loop
(double __tmp = ((F_CPU) / 4e3) * __ms;) was used. This was fixed in 1.7.1


Reply to this item at:


  Message sent via/by Savannah

reply via email to

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