I thought I had read in the documentation that the code to write to flash either should be or must be run out of RAM. Or, maybe I decided to use the mass erase function to save time and power. I've forgotten. Your scheme seems good if it works.

I know the TI supplied BSL copies itself to RAM before execution.  Why?

Dale

Chris Liechti wrote:
N. Coesel wrote:

Why would you copy more than one subroutine in RAM? The only thing you will
want in RAM is the code that actually programs the flash. The amount of
memory doesn't allow for allocating large fixed buffers for this.


the MSP430 can program itself when executing from flash. the flash controler handles that nicely.

of course, it's a problem if you want to program the entire flash, but then updating only parts of a program is tricky anyway.

right now, i'm implementing my own BSL (compatible with TI's BSL) that resides in the top 2kB of flash, which i won't delete in upgrades. (it currently is slightly larger than 1kB. maybe i'll reserve only 1.5kB)

chris

Reply via email to