⚠️ Hi there.. thanks for coming to the forums. Exciting news! we’re now in the process of moving to our new forum platform that will offer better functionality and is contained within the main Dialog website. All posts and accounts have been migrated. We’re now accepting traffic on the new forum only - please POST any new threads at//www.wsdof.com/support. We’ll be fixing bugs / optimising the searching and tagging over the coming days.
When DA14580 program is larger than 32KB. How to debug with keil? Because when the program is larger than 32KB, the compilation always fails and the memory is not enough.
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.
Another solution which not straight forward is would be to re-arrange the scatterfile 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内存映射和散射文件user manual for more information regarding the memory map and the scatter files.
Please note that if you are starting a new design, we strongly recommend moving into DA14531 and our latest SDK6.0.12, as it is much more improved. We have a lot of code examples, improved documentation, and there is also software roadmap support. For SDK5.0.4 there isn’t any roadmap support, as it is obsolete.
My DA14580 is plugged into a Flash IC. Because DA14580 ROM can only place programs below 32KB. But my program is larger than 32KB. I hope my program can be debugged online by Keil. What should I do?
Your problem is “how to open/compile an ARM Keil project which is more that 32KB”, or “you are unable to boot when the firmware is more than 32KB”? Can you please clarify it? In addition, if I am not mistaken, the application firmware is stored in an external SPI Flash. Is that correct? Is the device booting correctly?
Sorry, my English is not very good. I hope how to use keil to debug online when the size of my program exceeds 32K. I have a flash on my development board. Is it possible to download the program to FLASH and then perform online debugging.Does da14580 have a Chinese forum?
No problem… You cannot boot from SPI Flash and start a debugging session in ARM Keil IDE. When using the debugging session in ARM Keil IDE, the firmware is download to System-RAM and the DA14580 boots from there.
Yes, you can also enter our Chinese forums and post your questions there. This is the link:
Hi abc1724,
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.
Another solution which not straight forward is would be to re-arrange the scatterfile 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内存映射和散射文件user manual for more information regarding the memory map and the scatter files.
Please note that if you are starting a new design, we strongly recommend moving into DA14531 and our latest SDK6.0.12, as it is much more improved. We have a lot of code examples, improved documentation, and there is also software roadmap support. For SDK5.0.4 there isn’t any roadmap support, as it is obsolete.
Please check out the DA14531 product page:
//www.wsdof.com/products/connectivity/bluetooth-low...
Thanks, PM_Dialog
My DA14580 is plugged into a Flash IC. Because DA14580 ROM can only place programs below 32KB. But my program is larger than 32KB. I hope my program can be debugged online by Keil. What should I do?
Hi abc1724,
Your problem is “how to open/compile an ARM Keil project which is more that 32KB”, or “you are unable to boot when the firmware is more than 32KB”? Can you please clarify it? In addition, if I am not mistaken, the application firmware is stored in an external SPI Flash. Is that correct? Is the device booting correctly?
Thanks, PM_Dialog
Sorry, my English is not very good. I hope how to use keil to debug online when the size of my program exceeds 32K. I have a flash on my development board. Is it possible to download the program to FLASH and then perform online debugging.Does da14580 have a Chinese forum?
Hi abc1724,
No problem… You cannot boot from SPI Flash and start a debugging session in ARM Keil IDE. When using the debugging session in ARM Keil IDE, the firmware is download to System-RAM and the DA14580 boots from there.
Yes, you can also enter our Chinese forums and post your questions there. This is the link:
https://support.dialog-semiconductor.com/forums/dialog-smartbond-bluetooth-low-energy-%E2%80%93-software-dialog-%E2%80%9Csmartbond%E2%80%9D%E7%B3%BB%E5%88%97%E4%BD%8E%E5%8A%9F%E8%80%97%E8%93%9D%E7%89%99%E2%80%94%E8%BD%AF%E4%BB%B6
Thanks, PM_Dialog