This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Adding BLE softdevice to an existing emStudio project

Hello,

I've got some of the nRF5_SDK_15.0.0_a53641a examples running on my board, the blinky, twi scan etc. all work fine. The twi and spi examples still use the legacy nrf_drv_... api, I moved to nrfx_... api which required some #ifdef debugging. I hope this is the new recommended api.

Now I'd like to add ble_peripheral functionality to my emStudio project that has the peripheral functionality.

I added the c-files, include paths, some global defines (NRF_SD_BLE_API_VERSION=6;S132;SOFTDEVICE_PRESENT), the softdevice binary (debug_additional_load_file="sdk/components/softdevice/s132/hex/s132_nrf52_6.0.0_softdevice.hex").

The project builds but I can't run it because: "cannot load multiple load files because they overlap".

I tried to find a custom linker file, the one shown in emStudio seems to be generated. Also I compared many settings (and the emProject files) but could not find anything useful. May be I'm missing a magic define somewhere.

How do I tell emStudio that my code should now be relocated behind the softdevice binary?

It should look like this afterwards:

http://infocenter.nordicsemi.com/index.jsp?topic=%2Fcom.nordic.infocenter.s132.sds%2Fdita%2Fsoftdevices%2Fs130%2Fmem_usage%2Fmem_resource_reqs.html&cp=2_3_0_0_13_0_0

I admit that this is rather a emStudio question that a softdevice issue.

Parents
  • Hello,

    I didn't figure out how to do it in the gui, but in *.emProject the follwoing is set:

    linker_section_placement_macros="FLASH_PH_START=0x0;FLASH_PH_SIZE=0x80000;RAM_PH_START=0x20000000;RAM_PH_SIZE=0x10000;FLASH_START=0x26000;FLASH_SIZE=0x5a000;RAM_START=0x200022b8;RAM_SIZE=0xdd48"

    This is picked up by flash_placement.xml which configures the linker.

    And then the binary is linked correctly at the sepcified offset and can be loaded alongside the sofdevice.

Reply
  • Hello,

    I didn't figure out how to do it in the gui, but in *.emProject the follwoing is set:

    linker_section_placement_macros="FLASH_PH_START=0x0;FLASH_PH_SIZE=0x80000;RAM_PH_START=0x20000000;RAM_PH_SIZE=0x10000;FLASH_START=0x26000;FLASH_SIZE=0x5a000;RAM_START=0x200022b8;RAM_SIZE=0xdd48"

    This is picked up by flash_placement.xml which configures the linker.

    And then the binary is linked correctly at the sepcified offset and can be loaded alongside the sofdevice.

Children
No Data
Related