|
From: | David Kelly |
Subject: | Re: [avr-gcc-list] use of specifin RAM location |
Date: | Mon, 28 Nov 2005 21:21:59 -0600 |
On Nov 28, 2005, at 9:01 PM, David Kelly wrote:
Then in the linking stage define the location of the FPGA something likethis in Makefile: LDFLAGS= -Wl,-Map,address@hidden \ -Wl,--section-start=.eeprom=0x00810001 \ -Wl,--section-start=.fpga1=0x6000 \ -Wl,--section-start=.hsa2d=0x7000 \ -Wl,--section-start=.sram=0x2000 Just use the __attribute__ to tag variables as section .sram and the compiler will find places for them if you don't care about the order.
Oops, come to think of it "data-memory mapped" needs 0x800000 added as an offset so to indicate which memory space it belongs. Add 0x810000 for EEPROM as shown. Most of the above lands in FLASH code space.
-- David Kelly N4HHE, address@hidden ======================================================================== Whom computers would destroy, they must first drive mad.
[Prev in Thread] | Current Thread | [Next in Thread] |