Long addressing RAM
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2004-09-28 9:06 PM
3 REPLIES 3
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2004-09-28 12:22 AM
Posted on September 28, 2004 at 09:22
Hi,
I'm in trouble with a ST72F521R9: I need to store a large constant array (1024 float elements) in sector2, how can I do? I tried using both ''small memory model'' and ''large memory model'' but in any case the array will be allocated in sector0 (addresses 0xF19D and 0xF1F1 depending on memory model). This, declaring the array as ''float const''. Moreover, if I try to declare in RAM a float array, It's limited to 26 elements (more elements make the linker return an overflow error involving .data segment).; this because all variables (any type) will be allocated in short addressing RAM in both memory models. I tried forcing them @near, but with no result. I'm using STVD7 (simulator) with Cosmic compiler. I made no changes to the default segments settings in the linker options. Where I'm wrong? Regards DreeOptions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2004-09-28 4:46 AM
Posted on September 28, 2004 at 13:46
If the table is in rom then it needs declaring as const, eg.
const unsigned char* const pArray[]={ .... }; Regards sjoOptions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2004-09-28 9:06 PM
Posted on September 29, 2004 at 06:06in addition to what sjo says, if you want your table to be in a specific sector, you need to tell the compiler to put it at an address within that sector; see how to that. Regards, Luca (Cosmic)
