#! armcc -E
|
; *************************************************************
|
; *** Scatter-Loading Description File generated by uVision ***
|
; *************************************************************
|
|
#include ".\configuration\sdk_config.h"
|
|
#define SIZE_BOOTLOADER 0xA000
|
#define SIZE_FIXED_APP_IMAGE 0x37000
|
#define SIZE_FIXED_USER_FLASH (CONFIG_SETTINGS_SECTOR_NUM * 4096)
|
|
|
#if (CONFIG_OTA_IN_APP == 1 && CONFIG_FLASH_MAP_SIZE <= 0x3F000)
|
#error do not support ota back-up within 256K flash
|
#endif
|
|
/* bare program which means it can work without bootloader
|
* note image start at 0 address,and user can modify CONFIG_USER_FLASH_EXTENDED_SIZE size
|
*/
|
#if (!CONFIG_BOOT_ENABLE)
|
#define SIZE_IMAGE_HEADER 0
|
#define APP_IMAGE_START 0x00000000
|
#define APP_IMAGE_SIZE (CONFIG_FLASH_MAP_SIZE - SIZE_FIXED_USER_FLASH)
|
|
/* ota in bootloader and there are have no backup area. so it can expand image size user can use
|
* note it does not support ble ota
|
*/
|
#elif (!CONFIG_OTA_IN_APP)
|
#define SIZE_IMAGE_HEADER 512
|
#define APP_IMAGE_START 0x0000A000
|
#define APP_IMAGE_SIZE (CONFIG_FLASH_MAP_SIZE - SIZE_FIXED_USER_FLASH - SIZE_BOOTLOADER)
|
|
|
/* ota in bootloader and there are have a backup area.
|
* note it is used to adapt to condition that use want to ota in ble ways
|
*/
|
#else
|
#define SIZE_IMAGE_HEADER 512
|
#define CONFIG_USER_FLASH_EXTENDED_SIZE (0) /* user can change the value */
|
#define APP_IMAGE_START 0x0000A000
|
#define APP_IMAGE_SIZE (SIZE_FIXED_APP_IMAGE - CONFIG_USER_FLASH_EXTENDED_SIZE)
|
#endif
|
|
|
LR_IROM1 APP_IMAGE_START APP_IMAGE_SIZE { ; load region size_region
|
#if SIZE_IMAGE_HEADER
|
ER_IROM0 APP_IMAGE_START SIZE_IMAGE_HEADER { ; load address = execution address
|
*app_version.o
|
}
|
#endif
|
ER_IROM1 (APP_IMAGE_START + SIZE_IMAGE_HEADER) APP_IMAGE_SIZE { ; load address = execution address
|
*.o (RESET, +First)
|
*(InRoot$$Sections)
|
.ANY (+RO)
|
.ANY (+XO)
|
}
|
RW_IRAM1 0x20000000 0x0000C000 { ; RW data
|
.ANY (+RW +ZI)
|
*.o (.ramfunc)
|
}
|
}
|