This is the mail archive of the
ecos-devel@sourceware.org
mailing list for the eCos project.
AT91SAM7 HAL and CDL
- From: "Meiring, H, Mnr <meiring at sun dot ac dot za>" <meiring at sun dot ac dot za>
- To: <ecos-devel at ecos dot sourceware dot org>
- Date: Thu, 12 Jul 2007 17:56:50 +0200
- Subject: AT91SAM7 HAL and CDL
Hi, I finally got started with the ATMEL AT91SAM7A2 port, but have a few questions regarding porting.
I still have some distance to go but if you can confirm the following pls, all the edited files should be provided for with a diff file for updating, and the new port provided in a tar and those sent to this list.
How do I go about to change the directory structure?
As the hal structure currently stands
Common HAL - Common HAL
ARM HAL - Architectural HAL
AT91 HAL - Variant HAL
AT91SAM7 - Platform HAL
AT91SAM7SEK AT91SAM7XEK AT91SAM7AEK- Auxiliary HAL?s?
The AT91SAM7 platform HAL is currently located in the directory /AT91/AT91SAM7S/
If the following could perhaps be changed in the /HAL/ARM/AT91/ folder: change at91sam7s directory name to at91sam7
Then:
\packages\hal\arm\at91\at91sam7\current\cdl\ hal_arm_at91sam7s.cdl
=> \packages\hal\arm\at91\at91sam7\current\cdl\ hal_arm_at91sam7.cdl
\packages\hal\arm\at91\at91sam7\current\src\at91sam7s_misc.c
=> \packages\hal\arm\at91\at91sam7\current\src\at91sam7_misc.c
In the hal_arm_at91sam7.cdl file the following was changed:
compile at91sam7s_misc.c
=> compile at91sam7_misc.c
And in the ecos.db file:
package CYGPKG_HAL_ARM_AT91SAM7 {
alias { "Atmel AT91SAM7" hal_arm_at91sam7 arm_at91_sam7 }
directory hal/arm/at91/at91sam7
script hal_arm_at91sam7.cdl
hardware
description "
The at91sam7 HAL package provides the support needed to run eCos on
an Atmel AT91SAM7 family of CPUs."
}
Further the AT91 variant HAL contains really allot of platform specific macros. I am willing to re-locate the macros that are more applicable to the AT91SAM7 platforms from the AT91 Variant HAL to the AT91SAM7 Platform HAL if the powers that be want me to.
The CDL question in ?hal_arm_at91sam7s.cdl?:
What is the default flavor of and cdl option if none is specified. How I understand it, it would be the same as flavour none, but that would make cdl_option CYGHWR_HAL_ARM_ AT91SAM7S etc redundent, or am I understanding this wrong?
If I am right, is line #3 not supposed to be (!(?at91sam7s32? == CYGHWR_HAL_ARM_AT91SAM7) &&( CYGHWR_HAL_ARM_AT91SAM7S))
#1 cdl_option CYGBLD_HAL_ARM_AT91SAM7_USB {
#2 display "USB device"
#3 active_if {!( "at91sam7s32" == CYGHWR_HAL_ARM_AT91SAM7S) ||
#4 CYGHWR_HAL_ARM_AT91SAM7X ||
#5 CYGHWR_HAL_ARM_AT91SAM7XC}
#6 implements CYGINT_DEVS_USB_AT91_HAS_USB
default_value 1
no_define
description "
All but the AT91SAM7S32 and AT91SAM7A has the USB device"
}
I first want to understand it before I start doing mad stuff....
Regards
Hendrik Meiring