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

Getting error 0x0f while running two tasks parallelly on ble_app_hrs_freertos.

I have two tasks and I want to run those tasks one after the other.

currently when I comment on one of the task, the firmware running without any error.

if run those two parallelly I'm getting error APP_ERROR_HANDLER(NRF_ERROR_FORBIDDEN); error code 0xf.

Please suggest to me the proper method to run two tasks simultaneously.

Thanks in advance.

Parents
  • if run those two parallelly I'm getting error APP_ERROR_HANDLER(NRF_ERROR_FORBIDDEN); error code 0xf.

     Where did you get this error exactly? I mean what was the context and what was the function that returned this error?

  • /**@brief Function for application main entry.
     */
    int main(void)
     {
        bool erase_bonds;
    
        // Initialize modules.
        log_init();
        clock_init();
        
        flash_init();               /* Initialize the flash data storage */
    
        // Activate deep sleep mode.
        //SCB->SCR |= SCB_SCR_SLEEPDEEP_Msk;
        // Initialize modules.
        timers_init();
        // Configure and initialize the BLE stack.
        ble_stack_init();
    
        //buttons_leds_init(&erase_bonds);
        gap_params_init();
        gatt_init();
        services_init();
        advertising_init();
        conn_params_init();
        peer_manager_init();               /* Peer Manager initialization*/
    
    
        // Create a FreeRTOS task for the BLE stack.
        // The task will run advertising_start() before entering its loop.
        nrf_sdh_freertos_init(advertising_start, &erase_bonds);
            BLE_TASK();                   /* TASK-1*/
    
            pollTask();                   /*TASK-2*/
    
    
        NRF_LOG_INFO("HRS FreeRTOS example started.");
        // Start FreeRTOS scheduler.
        vTaskStartScheduler();
    
        for (;;)
        {
            APP_ERROR_HANDLER(NRF_ERROR_FORBIDDEN);
        }
    }
    

    I'm getting an error at  line number 43

Reply
  • /**@brief Function for application main entry.
     */
    int main(void)
     {
        bool erase_bonds;
    
        // Initialize modules.
        log_init();
        clock_init();
        
        flash_init();               /* Initialize the flash data storage */
    
        // Activate deep sleep mode.
        //SCB->SCR |= SCB_SCR_SLEEPDEEP_Msk;
        // Initialize modules.
        timers_init();
        // Configure and initialize the BLE stack.
        ble_stack_init();
    
        //buttons_leds_init(&erase_bonds);
        gap_params_init();
        gatt_init();
        services_init();
        advertising_init();
        conn_params_init();
        peer_manager_init();               /* Peer Manager initialization*/
    
    
        // Create a FreeRTOS task for the BLE stack.
        // The task will run advertising_start() before entering its loop.
        nrf_sdh_freertos_init(advertising_start, &erase_bonds);
            BLE_TASK();                   /* TASK-1*/
    
            pollTask();                   /*TASK-2*/
    
    
        NRF_LOG_INFO("HRS FreeRTOS example started.");
        // Start FreeRTOS scheduler.
        vTaskStartScheduler();
    
        for (;;)
        {
            APP_ERROR_HANDLER(NRF_ERROR_FORBIDDEN);
        }
    }
    

    I'm getting an error at  line number 43

Children
No Data
Related