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

GPIO Interrupt - stopped by vector catch

Hello, 

I got problem when I press button program go to interrupt mode, but than all stops because of vektor catch. Im using ble_app_uart example.

Here is my main function:

int main(void){
bool erase_bonds;
ret_code_t rc, err_code;

uint32_t * data_from_flash;

 
    timers_init();
    create_timers();
    GPIO_init();
   
       

    data_from_flash = (uint32_t *) flash_mode_address;
    switch(*data_from_flash){ 
        case 0xffffffff: 
                Beacon_start();
             break;                          
        case 0x10:      
                BLE_UART_init();
            break;

        default:
        break;
    }

    for(;;){

    }
    
}

flash_mode_address is set to 0x6D000. Because i didnt write anything to it, it will go to Beacon_start(). Also im using sd_flash_write() for writing flash.

void Button_Handler(nrf_drv_gpiote_pin_t pin, nrf_gpiote_polarity_t action){



}

Here is my button_handler. I dont have anything in it, but when im debugging it goes into and then says stopped by vector catch. 

Parents
  • Hello, 

    A vector catch indicates that a Hardfault exception has occurred. SES enables breakpoint on fault exceptions by default, but you can disable it by opening the breakpoints view and un-check the Hardfault exception (open view in debug session -> Ctrl + Alt + B):

    Have you verified through debugging that data_from_flash is indeed a valid pointer? 

Reply
  • Hello, 

    A vector catch indicates that a Hardfault exception has occurred. SES enables breakpoint on fault exceptions by default, but you can disable it by opening the breakpoints view and un-check the Hardfault exception (open view in debug session -> Ctrl + Alt + B):

    Have you verified through debugging that data_from_flash is indeed a valid pointer? 

Children
Related