Hi Dialog
I add my alg lib file to project. the size exceeds limit. can you tell me how to set the region to solve the problem.
*** Using Compiler 'V5.06 update 6 (build 750)', folder: 'C:\Keil_v5\ARM\ARMCC\Bin'
Build target 'prox_reporter_580'
linking...
.\out_580\prox_reporter_580.axf: Error: L6220E: Execution region ER_IROM5 size (32796 bytes) exceeds limit (31424 bytes). Region contains 24 bytes of padding and 1692 bytes of veneers (total 1716 bytes of linker generated content).
.\out_580\prox_reporter_580.axf: Error: L6221E: Execution region ER_IROM5 with Execution range [0x20000440,0x2000845c) overlaps with Execution region RW_IRAM50 with Execution range [0x20008000,0x20008888).
Not enough information to produce a SYMDEFs file.
Finished: 1 information, 0 warning and 2 error messages.
".\out_580\prox_reporter_580.axf" - 2 Error(s), 0 Warning(s).
Target not created.
Hi lewuyouc,
This means that your code exceeds the limitation. Which optimization level are you using which is the size the binary image?
Thanks, PM_Dialog
Hi PM_Dialog
using Optimization:Level3(-O3),C99 Mode. my alg lib .lib file is 16KB, add my alg lib the code side 6296 more than before,RAM:1764,ROM:6368.
if without my alg lib,the prox_reporter_580.hex file is 74KB, Program Size: Code=23996 RO-data=2312 RW-data=576 ZI-data=7592
Thanks for your replay!
lewuyouc
Hi lewuyouc,
The DA14580 has limited memory and most of your image code should fit in the ER_IROM5 which is 31.424 bytes, if you exceed the limit then the linker will fail to link your project. A possible quick solution would be to change the size of your ER_IROM5 from 0x7ac0 to 0x7bc0, this will give you 0x100 bytes (256 bytes). The limitation is that you won’t be able to boot from OTP. As I can see from you post, the size of your firmware is 32796 bytes, so you need 1372 bytes.
Another solution which is not straight would be to rearrange the scatterfile in order to serve a larger application. you can try the following steps considering that you are using extended sleep and your code won’t reside to the OTP. Again you won’t be able to use the OTP.
1. Increase the ER_IROM5 by changing the scatterfile and setting the ER_IROM5 to ER_IROM5 0x20000440 0x7bc0 to gain 0xff space.
2. Increase the code space in the ER_IROM5 by removing the RW_IRAM50 and add the available space in the ER_IROM5 section. Also you can move the RW_IRAM51 in a different address. A possible candidate to include the non-retained heap is the ZI_RET20 section. By doing this a continuous memory area from 0x20000440 to 0x20009000 of almost 35kB will be available for source code and RW data. In order to implement this follow the below instructions.
a. Remove the RW_IRAM50 and RW_IRAM51 sections
b. Change the size of the ER_IROM5 to ER_IROM5 0X20000440(0x9000 - 0x440)
c. The non retention heap will be moved, say in ZI_RET20, by adding the following line jump_table.o(heap_mem_area_not_ret) in both ZI_RET20 definitions.
Please check the嗯- b - 011 DA14580内存映射和散射文件document for getting more information regarding the memory map and the scatter files.
In conclusion, I would suggest you to have a look at the DA14585/6 product family and our new SDK6. This product family is ideal for adding Bluetooth low energy to products like remote controls, proximity tags, beacons, connected medical devices and smart home nodes. It supports all Bluetooth developments up to and including Bluetooth 5 and Bluetooth low energy Mesh. Plus, with 96 kB of RAM, the DA14585&6 have double the memory for user. Also, in the DA14585/6 support portal, you will be able to find great variety of software examples and user manuals that will really help you to getting started.
Thanks, PM_Dialog