How much heap does the BLE stack use?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
EyGe_3183606
Level 4
Level 4
25 replies posted 10 sign-ins 10 replies posted

Hi,

We would like to decrease the size of the heap in our OTA Fixed Stack Bootloader Project from 0x400 (1k) to something less.
We have PSOC 4 and our MCU is CYBLE-224110-00.

We just wanted to know if the BLE stack (written by Cypress) makes any use of the Heap memory and if so, what is the minimum size recommended to keep it?

Thanks,

David

0 Likes
1 Solution
GeonaP_26
Moderator
Moderator
Moderator
250 solutions authored 100 solutions authored 50 solutions authored

The SRAM memory utilisation varies with the component configuration, compiler selected, device, API usage etc.,

Please refer to the memory utilisation table available in section: API Memory Usage of BLE component datasheet.

View solution in original post

3 Replies
GeonaP_26
Moderator
Moderator
Moderator
250 solutions authored 100 solutions authored 50 solutions authored

The SRAM memory utilisation varies with the component configuration, compiler selected, device, API usage etc.,

Please refer to the memory utilisation table available in section: API Memory Usage of BLE component datasheet.

Thanks GeonaM.

I went to the datasheet to the chaprter you mentioned and indeed there is a breakdown of the memory including ROM, SRAM and Stack but with Heap. So my understanding is that the BLE component doesn't use Heap.

Thanks.

0 Likes

Stack bytes provided in BLE component datasheet stands for the heap bytes for the BLE stack alone. Sorry for the confusion in naming. We have forwarded your query to our product development team to address it in the next revision of BLE component datasheet.

The featureHeapReq parameter in the BLE.c generated source file provides an approximation of heap requirement for the BLE stack. Please note that the total SRAM requirement is dependent on the entire project configurations including BLE stack. Controlling SRAM Usage in PSoC® Applications - KBA93584 could be helpful.

0 Likes