Re: Flash Memory - Loading an Application of 2M size into 1M Flash memory



On 26 Sep 2006 03:02:19 -0700, "KBG"
<karthik.balaguru@xxxxxxxxxxxxxxx> wrote:

Hi Friends,

I have 1M flash memory allocated for Application. But the Application
size exceeds the
1M limit (Application size is 2M). But, now i cannot redesign the
hardware and fit in any extra Flash Memories to resolve this size issue
. I have RS232, Ethernet support on my
board. My Bootloader is loading the application perfectly. ( I tried
with a small application that
spits some strings on the hyperterminal ). Now the issue is with the
size of the original application which grew in size in the course of
time.

Since you have an Ethernet adaptor on the board, why not just put a PC
or some other device with a large mass storage on the LAN and load
only those segments currently needed into Flash (or preferably RAM).

In the old days with 16 bit computers typically restricted to 64 KiB,
large programs were divided into overlays stored to disk. The
initialisation routines could be in one overlay branch and initially
loaded into memory and when all initialisation was done, the actual
application code branch was loaded on the same addresses as the
initialisation code, overwriting it. Each overly branch could contain
a root and several alternative branches, thus the overlay structure
was actually an overlay tree.

While very simple overlays could be handled with ordinary linkers and
some application code, any complex overlay structure would definitely
need a linker that understands about overlay trees and can generate
the autoload vectors.

Overlays were used also on MS-DOS to handle larger programs that did
not fit into the 512 KiB or 640 KiB physical memory of the original
PC.

With the LAN, you could have a single file server and multiple
embedded system with a small memory loading overlay segments from the
file server over the LAN. A UDP frame is well capable of carrying 1
KiB segments over the net. Implementing UDP on a small device with
Ethernet is easy and does not require much code or buffer space.

You would have to handle the situations, when the Ethernet or file
server temporary becomes unavailable.

A program RAM at the embedded device would be preferable, since the
Flash has a limited number of write operations.

Paul

.



Relevant Pages

  • Re: XU1541 and more USB stuff
    ... memory. ... coming along nicely this week (FAT12/16/32/LFN support working for read ... for significantly more buffering reducing the overhead of the USB ... lots of flash and ram. ...
    (comp.sys.cbm)
  • Re: Memory Overlay - ADSP
    ... I am trying to get more info about External Memory Overlay. ... and that information is not necessarily available to the linker. ... to internal memory at runtime is called an overlay manager. ...
    (comp.dsp)
  • Re: Lifetime of flash memory
    ... FILE ON USB MEMORY" have come out of this. ... and overuse may wear out your memory stick pretty quickly. ... Do _not_ use journalling filesystems on flash memory sticks.) ...
    (Linux-Kernel)
  • Re: making a removable SSD drive nonremovable
    ... Using a FLASH based memory card in the way you suggest is a ... Putting in a FLASH based memory will make ... Are you certain that it's not battery backed RAM? ...
    (microsoft.public.windowsxp.hardware)
  • Re: making a removable SSD drive nonremovable
    ... Using a FLASH based memory card in the way you suggest is a very bad idea. ... Putting in a FLASH based memory will make Windows take a very significant performance hit. ... Are you certain that it's not battery backed RAM? ...
    (microsoft.public.windowsxp.hardware)