NRF_LOG_INFO() doesn't work after changing the RAM origin.

Hey Nordic,

The following are some specifications of my project.

  • nRF52833-DK
  • PCA10100
  • Softdevice is S122
  • Based on "ble_app_uart_c"
  • SDK 17.1.0
  • I am using VSCODE for flashing.

When I flash my project, the following are the logs taken from the J-Link RTT Viewer:

00> <info> app: log_init() is executed.
00> 
00> <info> app_timer: RTC: initialized.
00> 
00> <warning> nrf_sdh_ble: Insufficient RAM allocated for the SoftDevice.
00> 
00> <warning> nrf_sdh_ble: Change the RAM start location from 0x200027B0 to 0x200027C0.
00> 
00> <warning> nrf_sdh_ble: Maximum RAM size for application is 0x1D840.
00> 
00> <error> nrf_sdh_ble: sd_ble_enable() returned NRF_ERROR_NO_MEM.
00> 
00> <error> app: Fatal error

Then, I updated my memory in "ble_app_uart_c_gcc_nrf52.ld" file as it is suggested in logs. This is the memory part of the file after I change it:

MEMORY
{
  FLASH (rx) : ORIGIN = 0x1c000, LENGTH = 0x64000
  RAM (rwx) :  ORIGIN = 0x200027C0, LENGTH = 0x1d850
}

Then, I entered the following commands into the terminal:

rm -r .\_build\
clear; make -j all; make flash_softdevice; make flash

After all the processes are done, I don't see any logging into RTT Viewer. Even the one after log_init() doesn't appear. Do you have any idea what is happening? You can download the unchanged memory version of my project below:

6837.ble_app_uart_c_copy.zip

Thanks,

Omer

Parents Reply Children
  • Hey Simonr,

    It doesn't seem like you have edited the RAM Size as well to match the newly edited RAM START

    Yes, you are right, I missed that part. After doing so, the issue is resolved.

    We have a guide explaining how to do this and how to calculate SIZE and START available here.

    I've read the reference that you suggested to me, it looks beneficial but I don't use any of those embedded software environments but VSCODE. But in case of any similar issue, it seems like logged suggestions will resolve the issue again.

    Thanks,

    Omer

Related