AVR C Runtime Library - Bugs: bug #28756, Bug in AVR libc 1.6.7 (power.h for...
You are not allowed to post comments on this tracker with your current authentication level.
bug #28756: Bug in AVR libc 1.6.7 (power.h for 8-bit AVR)
Submitter: | Lucas <kukiz100> | ||
Submitted: | Thu 28 Jan 2010 11:17:39 AM UTC | ||
Category: | Header | Severity: | 3 - Normal |
Priority: | 5 - Normal | Item Group: | Header files |
Status: | Fixed | Assigned to: | joerg_wunsch |
Percent Complete: | 0% | Open/Closed: | Closed |
Release: | 1.6.7 | Fixed Release: | 1.6.3 |
Jump to the original submission
Wed 03 Feb 2010 10:44:48 AM UTC, comment #14: |
Lucas <kukiz100> |
Wed 03 Feb 2010 08:10:46 AM UTC, comment #13: I can now see the problem with that code. They stupidly
|
Joerg Wunsch <joerg_wunsch> |
Tue 02 Feb 2010 11:26:58 AM UTC, comment #12: But: I cannot reproduce it with that, and obviously, your
|
Joerg Wunsch <joerg_wunsch> |
Tue 02 Feb 2010 10:55:11 AM UTC, comment #11: I wrote about it in third post, source code is in first attachment (file #19561: test_usb_mass_storage.rar added by kukiz100) |
Lucas <kukiz100> |
Tue 02 Feb 2010 10:24:12 AM UTC, comment #10:
|
Joerg Wunsch <joerg_wunsch> |
Tue 02 Feb 2010 10:06:20 AM UTC, comment #9: I have the same error with AT90USB1287:
|
Lucas <kukiz100> |
Tue 02 Feb 2010 08:54:47 AM UTC, comment #8: Yes, the ATmega128RFA1 was (accidentally) missing from the
|
Joerg Wunsch <joerg_wunsch> |
Tue 02 Feb 2010 08:49:50 AM UTC, comment #7: I have tested out Joerg's snippet with -mmcu=atmega128rfa1 -W -Wall, using WinAVR. With WinAVR-20090313, you get an error ("clock_div_1" undeclared, and a warning implicit declaration of function "clock_prescale_set"). This particular avr is missing from the list for the clock prescale micros.
|
David Brown <davidbrown> |
Tue 02 Feb 2010 07:48:57 AM UTC, comment #6: Thanks for the error message. Still, I cannot reproduce
|
Joerg Wunsch <joerg_wunsch> |
Tue 02 Feb 2010 05:51:25 AM UTC, comment #5: Sorry, I was inattentive with "infinity loop" :).
|
Timur Gilfanov <timurgilfanov> |
Mon 01 Feb 2010 01:05:34 PM UTC, comment #4: do { ... } while(0) is not an infinite loop. Think again
|
Joerg Wunsch <joerg_wunsch> |
Mon 01 Feb 2010 12:52:17 PM UTC, comment #3: I'm have his bug in WinAVR 20100110 too. In clock_prescale_set(x) I found infinity loop and error disappear when I remove loop:
|
Timur Gilfanov <timurgilfanov> |
Thu 28 Jan 2010 09:41:15 PM UTC, comment #2: In attachment I put my whole project. I use Programmers Notepad and "make all" command (newest WinAVR - 20100110). In earlier release (20090313) I had no problems. |
Lucas <kukiz100> |
Thu 28 Jan 2010 12:06:31 PM UTC, comment #1: Please attach a file to reproduce this problem, as well as
|
Joerg Wunsch <joerg_wunsch> |
Thu 28 Jan 2010 11:17:39 AM UTC, original submission:
There is a bug in power.h file. While I am using a macro "#define clock_prescale_set(x) \" compiler shows me error.
|
Lucas <kukiz100> |
Depends on the following items: None found
Items that depend on this one: None found
Follow 11 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2010-02-03 | joerg_wunsch | Status | Confirmed | Fixed | |
Assigned to | None | joerg_wunsch | |||
Open/Closed | Open | Closed | |||
Fixed Release | None | 1.6.3 | |||
2010-02-03 | joerg_wunsch | Status | Need Info | Confirmed | |
2010-02-02 | timurgilfanov | Attached File | - | Added compile_error, #19605 | |
2010-02-01 | timurgilfanov | Attached File | - | Added power.h, #19590 | |
Attached File | - | Added power.h, #19591 | |||
2010-01-28 | kukiz100 | Attached File | - | Added test_usb_mass_storage.rar, #19561 | |
2010-01-28 | joerg_wunsch | Status | None | Need Info | |
2010-01-28 | kukiz100 | Carbon-Copy | - | Added kukiz100 |
Powered by Savane 3.13-02a9.
Corresponding source code
At first I want to apologize for my behaviour (sending you my whole project).
Your suggestion Joerg about
#define Set_cpu_prescaler(x) (clock_prescale_set(x))
was fine. I changed it to
inline void Set_cpu_prescaler(clock_div_t x);
inline void Set_cpu_prescaler(clock_div_t x)
{
clock_prescale_set(x);
}
and it works!. Thank You very much!