The memory map for program memory and RAM when the SoftDevice is enabled is described in this section.
Memory resource map illustrates the memory usage of the SoftDevice alongside a user
application. The flash memory for the SoftDevice is always reserved, and the application
program code should be placed above the SoftDevice at APP_CODE_BASE
.
The SoftDevice uses the first eight bytes of RAM when not enabled. Once enabled, the RAM
usage of the SoftDevice increases. With the exception of the call stack, the RAM usage
for the SoftDevice is always isolated from the application usage. Therefore, the
application is required to not access the RAM region below
APP_RAM_BASE
. The value of APP_RAM_BASE
is obtained by
calling sd_softdevice_enable
, which will always return the required
minimum start address of the application RAM region for the given configuration. An
access below the required minimum application RAM start address will result in undefined
behavior. The RAM requirements of an enabled SoftDevice are detailed in S140 Memory resource requirements for RAM.