Dear
I am trying to locate the data area of application code from device (nRF52840).
From here, it show me the bootloader will locate at from 0x000F 8000 – 0x000F E000(24KB) and application data will locate from some where of application area to 0x0007 7FFF.
So I do some thing below:
Step 1. Erase a dongle by " nrfjprog --e" and flash "nRF5_SDK_16.0.0_98a08e2\examples\dfu\open_bootloader \pca10059_usb_debug"
Step 2. To take look the MBR and bootloader area by Programmer tools:
MBR: 0x0000 0000 --- 0x0000 0FFF 4096 Byte
BL : 0x000E 0000 ---- 0x000F DFFF 122880 Byte
Step 3: Add hex of SD: S140 v7.0.1 in Programmer tools
MBR或APP: 0x0000 0000 ---- 0x0000 0AFF 2816 Byte
SD: 0x0000 1000 ---- 0x0002 6597 152984 Byte
Step 4: Add hex of Light-switch server for PCA10059 in Programmer tools:
APP1:0x0002 7000 ---- 0x0004 6009 126986 Byte
APP2:0x0004 600C ---- 0x0004 87bBB 10160 Byte
Step 5: Write them to device(nrf52840), works,then take look the memory layout of the dongle:
MBR: 0x0000 0000 --- 0x0000 0FFF 4096 Byte
SD: 0x0000 1000 --- 0x0002 6FFF 155648 Byte
APP: 0x0002 7000 --- 0x0004 87BB 137148 Byte
BL : 0x000E 0000 ---- 0x000F DFFF 122880 Byte
Step 6: Provision the dongle as a mesh node and bonding keys , Then take look the memory layout of the dongle again.
Nothing be changed.
I have some question about the result above.
Q1: Why the bootloader area is not at from 0x000F 8000 – 0x000F E000(24KB) ? Why it need more 96KB?
Q2: The bootloader occupy the application area which should be application data. Doesn't it have any effect on the application data? How and when inform application code to make tit getting data area address? How and from where I can get the address?
Q3: I noticed that when the application is loaded in, the application code is split into two parts. Can you explain why?Are there any special differences between the two parts?
Q4: After step 6, the application should have some data to be saved to data area, but the data do not be displayed in programmer tools. Does the data do not be read by programmer tools or they be written into the 96KB area which be occupied by bootloader ?
Q5: Same as Q4 , The application be loaded by bootloader, so the bootloaser setting page should be created. The bootloader setting area and MBR parameter is empty too. Is there any link fro bootloader setting page and MBR parameter format.
Q6. Where and how I can get the application data size?
Thanks,
Di-sheng