Hello
The nRF51822 has as I understand it 256kByte flash and 16kByte SRAM. If I run the S110 softdevice, how much sram/flash memory is available to my application program?
Regards Erik
Hello
The nRF51822 has as I understand it 256kByte flash and 16kByte SRAM. If I run the S110 softdevice, how much sram/flash memory is available to my application program?
Regards Erik
Have you read the S110 SoftDevice Specification? Table 16 lists the flash and RAM requirements of the softdevice.
80 kB flash and 8 kB of static RAM for S110 leaves 176 kB of flash and 8 kB of RAM for the application. Also note that S110 uses up to 1.5 kB of stack, so you must make sure that your stack is big enough to accomodate both this and your application's requirement.
Thanks for the answer.
I am still trying to figure out if it will be enough for my needs. The flash would be ok, but I the available amount of ram (6.5kB) is on the low side. Is it possible to configure how much RAM to allocate to the softdevice? I imagine that if I only use for instance one simple service it would not really use all 8k allocated to to it?
/Erik
Unfortunately, there is currently no way to configure the RAM consumption of the softdevice, but this is something that's being considered for future releases, so it might happen some time in the future.
To clarify: does the S110 share the system stack (i.e. 0x20004000, growing downwards) with the app?
In other words, you say above that the application has 8KB of RAM available. If the S110 uses up to 1.5KB of stack, that only leaves 6.5KB for both application RAM and application stack; is that right?
Exactly where the stack is located in RAM is dependent on toolchain, but you're right that the S110 will use of the MSP stack defined by the application. Your understanding is therefore correct.