This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

about softdevice region RAM

Dear Sir

In nRF51822 xxAA (Ram is 16kB), softdevice(s120) is using RAM (address: 0x2000_0000 ~ RAM_R1_BASE).

I think that SoftdDevice region is used, after sd_softdevice_enable() is called.

I have 2 questions about this region.

(1) If sd_softdevice_enable() isn't called, Is SoftDevice region not used ?

(2) After (1), If I change SoftDevice region's data and call sd_softdevice_enable(), is SoftDevice working properly?

Thank you.

Parents
  • Talking with respect to S120 SDS v2.1

    1. That is true, the scatter loading is only done when you enable the softdevice. This is documented in the S120 SDS. A minimum of 8 bytes is still used so that when softdevice is not enable the the APP_RAM_BASE can be 0x20000008

    2. not sure what you mean by changing softdevice region's data. If in your app you call softdevice_enable anytime, then softdevice will takeover the RAM from 0x20000000-0x20002800. If you app uses this reserved region and then call softdevice_enable then softdevice will work properly because it will take full control of that reserved RAM, but your app wont work properly and it will hardfault because it will try to use protected reserved space of softdevice for which the hardware protection is enable in the call sd_softdevice_enable. See NRF_MPU->RLENR0.

  • Dear Aryan.

    Thank you for answer.

    I'll use RAM region of softdevice for my initial code. After initialization, call 'sd_softdevice_enable()' for BLE Protocol stack.

    Thanks and best regards.

Reply Children
No Data
Related