??? 09/30/06 18:13 Modified: 09/30/06 18:36 Read: times |
#125446 - Flash is Not RAM Responding to: ???'s previous message |
Benjamin Khan wrote:
Is it possible to use the program flash as RAM for temporary storage? Does any microcontroller support such a feature? Well, you can't really think of flash as RAM. RAM stands for "random access memory". With RAM, you can read or write to any address at any time. Flash memory is different. Generally speaking, you can only write to an address that has been previous erased, and you have to erase the cells in groups called "blocks". The size of each block depends on the device, and a single device may contains blocks of different sizes. Find a data sheet to learn the details. Now, if we change your question to, "Is it possible to use the program flash as memory for temporary storage?", the answer is "maybe". It depends on a lot of things. Here are some I have thought of:
There may be other considerations that I have not thought of. In order to consider flash for temporary storage, you need to first understand how flash memory works, and then think very carefully about how you are planning to use it. -- Russ |