AVR C Runtime Library - Bugs: bug #23032, Define PORTxn, PINxn, DDxn bit...
You are not allowed to post comments on this tracker with your current authentication level.
bug #23032: Define PORTxn, PINxn, DDxn bit names in iomxx4.h.
Submitter: | Eric Weddington <arcanum> | ||
Submitted: | Wed 23 Apr 2008 06:32:50 PM UTC | ||
Category: | Header | Severity: | 3 - Normal |
Priority: | 5 - Normal | Item Group: | Header files |
Status: | Fixed | Assigned to: | arcanum |
Percent Complete: | 100% | Open/Closed: | Closed |
Release: | 1.6.2 | Fixed Release: | 1.7.0 |
Wed 23 Apr 2008 06:41:01 PM UTC, comment #1: |
Joerg Wunsch <joerg_wunsch> |
Wed 23 Apr 2008 06:32:50 PM UTC, original submission:
Define PORTxn, PINxn, DDxn bit names in iomxx4.h. This is to be consistent with XML device files and with iom1284p.h. |
Eric Weddington <arcanum> |
No files currently attached
Depends on the following items: None found
Items that depend on this one: None found
Carbon-Copy List
Follow 5 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2008-04-24 | arcanum | Status | None | Fixed | |
Percent Complete | 0% | 100% | |||
Assigned to | None | arcanum | |||
Open/Closed | Open | Closed | |||
Fixed Release | None | 1.7.0 |
Powered by Savane 3.13-bb6a.
Corresponding source code
Hmm, are you sure?
I see PORTxn, DDRxn, and PINxn bit names /are/ defined in
avr/iom1284p.h. However, the "generic" bit names (Pxn) are
not defined for that device. They should probably be
supplied through avr/portpins.h. However, the logic there
is just the opposite of what would be needed: they assume
the device's header file defines whatever Pxn bits are
applicable for each device, and then conditionally derive
PORTxn names from those.
This should probably turned around: make avr/portpins.h
define Pxn based on the presence of PORTxn. Alas, this
requires to rewrite all the existing device header files.
Another option would be to extend avr/portpins.h like:
#if defined(PORTA0) && !defined(PA0)
# define PA0 PORTA0
#endif