NCS BLE Project using too much flash

Hi All,

I am looking for assistance with trying to reduce flash usage of my project. 
I am using NCS v2.6 with an nRF52832.

Attached is my prj.conf file. The major SDK features being used are:
- BLE
- DIS and BAS services
- 1 custom BLE service
- Extended advertising
- PWM Leds
- SAADC for battery measuring
- MCUboot for OTA
- Crypto functionality

My prj.conf already includes many of the configuration suggestions from Memory Optimization with the nRF Connect SDK - Software - nRF Connect SDK guides - Nordic DevZone (nordicsemi.com) and the minimal prj.conf, but the flash usage exceeds the available size by a few kb. I've noticed that enabling extended advertising alone adds about 34kb of flash usage which seems excessive. I am currently running under the premise that I cannot remove any of the major features in order to reduce memory usage. Any tips or advice would be greatly appreciated, thanks! 
5078.prj.conf

Parents Reply
  • Hi, I've gone through and disabled as many features as I can as well as reducing the buffers to the minimum amounts allowable for the specific project. The amount of additional space saved was less than 50 bytes. Do you know why extended advertising uses an additional 34kb? Is there any ways to reduce this? I am only using about 40 bytes in my advertising data and don't need all 1650, but setting 

    CONFIG_BT_CTLR_ADV_DATA_LEN_MAX=40
    only reduced the flash usage by 1 byte. 
Children
Related