Lets assume i have 3 hex files:
-
softdevice.hex (addresses 0x0 to 0x1f000)
-
mySoft1.hex (addresses 0x1f000 to (0x1f000 + size of my program) and 0x7ff00 to 0x7ff80)
-
mySoft2.hex (addresses from 0x7ff80 to 0x80000)
I would like to program all these hex files using nrfjprog. The problem: flash is programmed in 4kB sectors, so whole data from certains sectors are erased (writing mySoft1.hex after mySoft2.hex will erase 0x7f000-0x80000 locations). My question is how to program one page of memory preserving the already written data.