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

NRF_ERROR_SVC_HANDLER_MISSING on SPI master open

I get NRF_ERROR_SVC_HANDLER_MISSING error in spi_open function.

uint32_t err = sd_nvic_ClearPendingIRQ(p_spi_instance->irq_type);
APP_ERROR_CHECK(err);

I'm using dfu_dual_bank_ble_s110_pca10028 project for my bootloader project. I understand that SD must be initialized before SPI initialization, but I don't need SD in this moment since I will flash the SD with my functions and not MBR. This bootloader uses SPI external flash to read data which must be flashed, since SD is one of the thing I must update, it should not be initiated.

Any way to initialize SPI in this example without enabling the SD?

Thank you!

Br, Mladen

Parents
  • You need to replace all sd_xx calls with non sd calls. For example replace sd_nvic_ClearPendingIRQ with NVIC_ClearPendingIRQ from CMSIS

  • Example with dfu_dual_bank_ble_s110_pca10028 which is not working:

     int main(void)
    {
        // This check ensures that the defined fields in the bootloader corresponds with actual
        // setting in the nRF51 chip.
        APP_ERROR_CHECK_BOOL(*((uint32_t *)NRF_UICR_BOOT_START_ADDRESS) == BOOTLOADER_REGION_START);
        APP_ERROR_CHECK_BOOL(NRF_FICR->CODEPAGESIZE == CODE_PAGE_SIZE);
    	
    	
        // initialize
    		scheduler_init();
        timers_init();
    		app_bsp_init();
    		spi_init();
    	
    		
    		// I use spi_master_send_recv call in this function => example not working, remove the call, and all is working
    		bootloader_execute();
    	
    	
    		ble_stack_init(true);
    		bootloader_app_start(DFU_BANK_0_REGION_START);
    		
        NVIC_SystemReset();
    }
    
Reply
  • Example with dfu_dual_bank_ble_s110_pca10028 which is not working:

     int main(void)
    {
        // This check ensures that the defined fields in the bootloader corresponds with actual
        // setting in the nRF51 chip.
        APP_ERROR_CHECK_BOOL(*((uint32_t *)NRF_UICR_BOOT_START_ADDRESS) == BOOTLOADER_REGION_START);
        APP_ERROR_CHECK_BOOL(NRF_FICR->CODEPAGESIZE == CODE_PAGE_SIZE);
    	
    	
        // initialize
    		scheduler_init();
        timers_init();
    		app_bsp_init();
    		spi_init();
    	
    		
    		// I use spi_master_send_recv call in this function => example not working, remove the call, and all is working
    		bootloader_execute();
    	
    	
    		ble_stack_init(true);
    		bootloader_app_start(DFU_BANK_0_REGION_START);
    		
        NVIC_SystemReset();
    }
    
Children
No Data
Related