Keil uVision V5 Legacy Nordic Project Compile Errors

Hello,

I am trying to compile a legacy Nordic Project for evaluation purposes and I am getting some compile errors. The details are as follows:

Project: https://github.com/NordicPlayground/nrf52-ble-image-transfer-demo

Keil: uVision V5.38.0.0 MDK-Lite

ARM Compiler: V5.06 Update 6 (Build 750)

Nordic SDK: v16.0.0.

Nordic SoftDevice: S132 v7.0.1

Keil nRF_DeviceFamilyPack: 8.44.1

Other settings:

The compile errors I am getting as as follows:

linking...
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrf_drv_ppi_init (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_ppi_channel_alloc (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_ppi_channel_assign (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_ppi_channel_enable (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_saadc_buffer_convert (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_saadc_channel_init (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_saadc_init (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_saadc_sample_task_get (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_timer_enable (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_timer_extended_compare (referred from main.o).
.\_build\nrf52832_xxaa.axf: Error: L6218E: Undefined symbol nrfx_timer_init (referred from main.o).
Not enough information to list image symbols.
Not enough information to list load addresses in the image map.

I removed the default ..\nRF5SDK160098a08e2\modules\nrfx\mdk folder from the C/C++ include table and replaced it with ..\Arm\Packs\NordicSemiconductor\nRF_DeviceFamilyPack\8.44.1\Device\Include folder

I noticed that in the apply_old_config.h file all of the drivers seem to be disabled even though in the sdk_config.h file, the necessary drivers are enabled.

I am sure I am doing something wrong in the file structures or some configurations.

Please advise.

Thanks,

Adnan

Parents
  • Hi

    After another look, the INVALID_STATE from the nrf_sdh_enable_request(); function should only be triggered if the SoftDevice is already enabled somehow.

    ret_code_t nrf_sdh_enable_request(void)
    {
        ret_code_t ret_code;
    
        if (m_nrf_sdh_enabled)
        {
            return NRF_ERROR_INVALID_STATE;
        }

    This is usually due to the ble_stack_init() being called twice or when a bootloader has been used before the main application to do DFU over BLE, that has not disabled the SoftDevice after being done and just directly jumped into the main application. The RAM and Flash memory for specific releases can be found in the release notes downloadable here, but they are these should be correct for v7.0.1 as well. 

    Best regards,

    Simon

Reply
  • Hi

    After another look, the INVALID_STATE from the nrf_sdh_enable_request(); function should only be triggered if the SoftDevice is already enabled somehow.

    ret_code_t nrf_sdh_enable_request(void)
    {
        ret_code_t ret_code;
    
        if (m_nrf_sdh_enabled)
        {
            return NRF_ERROR_INVALID_STATE;
        }

    This is usually due to the ble_stack_init() being called twice or when a bootloader has been used before the main application to do DFU over BLE, that has not disabled the SoftDevice after being done and just directly jumped into the main application. The RAM and Flash memory for specific releases can be found in the release notes downloadable here, but they are these should be correct for v7.0.1 as well. 

    Best regards,

    Simon

Children
  • Hello Simon,

    The ble_stack_init() is only called once in the main function. The RAM and Flash memory values being used are:

    FLASH_PH_START=0x0

    FLASH_PH_SIZE=0x80000

    RAM_PH_START=0x20000000

    RAM_PH_SIZE=0x10000

    FLASH_START=0x26000

    FLASH_SIZE=0x5a000

    RAM_START=0x20004010

    RAM_SIZE=0xd568

    This line: "when a bootloader has been used before the main application to do DFU over BLE, that has not disabled the SoftDevice after being done and just directly jumped into the main application." Is confusing I am not sure what you mean, also if this is the case how do I fix it?

    Lastly, this issue seems to disappear when I am in debug mode.

    Please advise.

    Thanks,

    Adnan

Related