2005-02-22 02:12 PM
Possible Memory Mapping Scheme for IAP
2011-05-17 03:06 AM
Hello,
Is it possible in PSDSoft to declare one of the flash memory banks as program and data space at the same time? I ask because in the data sheets they mention a little something about combined space modes. Let me illustrate with an example; At Power-up: (Page 0) Code Space: Fs0: 0x0000 – 0x7FFF Csboot: 0x8000 – 0xFFFF Data Space: Fs1: 0x8000 – 0xFFFF After 1st IAP: (Page 1) Code Space: Fs1: 0x0000 – 0x7FFF Csboot: 0x8000 – 0xFFFF Data Space: Fs0: 0x8000 – 0xFFFF The reason I ask is because I’m trying to have one image of the application in memory at all times so that if IAP fails, I have something there to rollback to. I’ll start by JTAGing to store the initial program in fs0 and the bootloader in csboot. First time I’ll update fs1, if it fails, status bytes never change, load fs0. If the update is successful, set fs1 status byte to good, fs0 status byte to bad and load fs1 (Page 1). The second time I’ll update fs0, if it fails, status bytes never change, load fs1. If the update is successful, update the status bytes and load fs0 (Page 0). Etc…. Thanks