[Icc-mot] tables in Flash not RAM

Wade A Smith warm38 at juno.com
Wed Dec 19 11:45:50 PST 2007


How do I get the table into Flash?


--------------------- code

#define MENU_MAX_MSGS           3
const INTU8 *menuTable[MENU_MAX_MSGS+1] =
{
    {"\r\nFirst Menu Line\r\n"},
    {"\r\nThe Second Menu Line\r\n"},
    {"\r\nThe Third Menu Line\r\n"},
    {""}    // end of table
};


--------------------- generated code
                        .area data
 3020            _menuTable::
 0020                   .blkw 1
                        .area idata
--- 0020 03B8              .word L22
                        .area data
 0022                   .blkw 1
                        .area idata
--- 0022 0375              .word L23
                        .area data
 0024                   .blkw 1
                        .area idata
--- 0024 032D              .word L24
                        .area data
 0026                   .blkw 1
                        .area idata
--- 0026 03E7              .word L21

---------------------

menuTable is at $3020 which is a RAM address.  Any problems and I lose
the addresses of the strings.
L22, L23, L24 and L21 are in Flash at 0x5###.


How do I get menuTable to be in Flash and NOT RAM?

'const' does nothing.  If I leave out 'const', it does the same -- the
variable is in RAM and the strings are in Flash and I still cant see the
variables.

wade
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://dragonsgate.net/pipermail/icc-mot/attachments/20071219/92bbbda6/attachment.html


More information about the Icc-mot mailing list