Is it possible to write a flash page while executing code fetched from flash? (obviously I mean writing a page that doesn't contain code).
Sometimes processors have separate banks to allow this behavior but this is not the case for DSC.
Thank you,
CDS.
You can write to DataFlash while executing from either Bootflash or ProgramFlash, or you can write to either Bootflash or ProgramFlash while executing from the other one, but not within the same bank, as stated. You don't have to be executing in RAM, but you cannot be executing in the flash bank that you are trying to erase/program.
No. Unless the code is in a separate bank, any attempt to program the Flash is going to disrupt the reading of any code from it. You have to load the code doing the Flash programming into RAM. There are quite a few threads on this subject in the forums. Try searching for "executing/loading code from RAM" as a starting point.
---Tom