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

compiler ERROR UART code

Hi, i have been working on initializing the UART periferial based on the UART example in the SDK5. I got following error.

1> error: unplaced section: .log_dynamic_data_balloc_log_mempool [nrf_log_frontend.o], size=4, align=2
1> error: unplaced section: .log_const_data_app [nrf_log_frontend.o], size=8, align=4
1> error: unplaced section: .nrf_balloc [nrf_log_frontend.o], size=28, align=4
1> error: unplaced section: .log_dynamic_data_app [nrf_log_frontend.o], size=4, align=2
1> error: undefined symbol: __start_log_const_data
1> error: undefined symbol: __start_log_filter_data

I know that i probably missed a header file or something simular but i was not able to find out which.

Please help

Parents
  • Hi,

    It looks like you are missing definitions for some sections used by the logger library in the linker configuration. If you are using SES(?) you can refer to flash_placement.xml of one of the examples that use logging. There you will see for instance this line:

        <ProgramSection alignment="4" keep="Yes" load="Yes" name=".nrf_balloc" inputsections="*(.nrf_balloc*)" address_symbol="__start_nrf_balloc" end_symbol="__stop_nrf_balloc" />
    

    And similar for log_const_data etc. You need to add these configurations to your project.

  • <ProgramSection alignment="4" keep="Yes" load="Yes" name=".log_const_data" inputsections="*(SORT(.log_const_data*))" address_symbol="__start_log_const_data" end_symbol="__stop_log_const_data" />
    <ProgramSection alignment="4" keep="Yes" load="Yes" name=".nrf_balloc" inputsections="*(.nrf_balloc*)" address_symbol="__start_nrf_balloc" end_symbol="__stop_nrf_balloc" />
    <ProgramSection alignment="4" keep="Yes" load="Yes" name=".log_dynamic_data" inputsections="*(SORT(.log_dynamic_data*))" runin=".log_dynamic_data_run"/>
    <ProgramSection alignment="4" keep="Yes" load="Yes" name=".log_const_data" inputsections="*(SORT(.log_const_data*))" address_symbol="__start_log_const_data" end_symbol="__stop_log_const_data" />
    <ProgramSection alignment="4" keep="Yes" load="Yes" name=".log_dynamic_data" inputsections="*(SORT(.log_dynamic_data*))" runin=".log_dynamic_data_run"/>
    <ProgramSection alignment="4" keep="Yes" load="Yes" name=".log_filter_data" inputsections="*(SORT(.log_filter_data*))" runin=".log_filter_data_run"/>
    <ProgramSection alignment="4" keep="Yes" load="Yes" name=".nrf_balloc" inputsections="*(.nrf_balloc*)" address_symbol="__start_nrf_balloc" end_symbol="__stop_nrf_balloc" />

    I added the following lines to the flash_placement folder but the error Messages are the same

  • Can you upload your project here so I can look at it and perhaps try to build it?

Reply Children
No Data
Related