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

Can't run modified nrf51-DK example on custom board

Hi. I took the ble_central/experimental/ble_app_blinky_c example and modified it for my needs. It works on the nrf51-DK. Now I want to use it on a custom board with nrf51822qfab. I modified the Makefile in the following way:

changed LINKER_SCRIPT to nrf51_xxab.ld, changed the flags to -DNRF51822.

Run make flash_softdevice, and then make flash. And it doesn't work. (The simple blinky example does work) After hours of trying to understand the problem (this is my first time with Nordic), I found this thread . Now I know that the program gets stuck on

SOFTDEVICE_HANDLER_INIT(&clock_lf_cfg, NULL);

I tried to make the same change in clock settings (like in the thread) but it didn't help... Please help.

Parents
  • Hi. Didn't want to open a new thread, because I have the same issue with a different example. This time it's the "BLE Services, a beginner's tutorial". The code runs on the nrf51-DK but gets stuck (reset?) on the same SOFTDEVICE_HANDLER_INIT line. I use the same linker script as was suggested here and the clock is set to NRF_CLOCK_LF_SRC_RC. What is the problem this time? Thanks.

  • Did you also changed the size of the FLASH and RAM? The RAM should be 0x4000 (16K) less and the FLASH should be 0x20000 (128K) less (compared to this):

    MEMORY
    {
      FLASH (rx) : ORIGIN = 0x1b000, LENGTH = 0x5000
      RAM (rwx) :  ORIGIN = 0x20002080, LENGTH = 0x1f80
    }
    

    Did you also set the .rc_ctiv and .rc_temp_ctiv in addition to NRF_CLOCK_LF_SRC_RC?

Reply Children
No Data
Related