This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Problems of using nrfx IPC

I want to send an interrupt instruction from appcore to netcore by using IPC.

Implementation code in appcore:


void ipc_event_handler(uint32_t event_mask, void * p_context)
{
        
}


void main(void)
{
        nrfx_ipc_init(12, ipc_event_handler, NULL);
        nrfx_ipc_send_task_channel_assign(3, 3);

        while(1)
        {
                
               nrfx_ipc_signal(3);
               k_sleep(K_MSEC(1000));

        }

}

Implementation code in netcore:

void ipc_event_handler(uint32_t event_mask, void * p_context)
{
    if(event_mask == 3)
    {
        LOG_INF("===== IPC 3 =====");
    }
}


void main(void)
{
        
        nrfx_ipc_init(1, ipc_event_handler, NULL);
        nrfx_ipc_receive_event_channel_assign(3, 3);

        nrfx_ipc_receive_event_enable(3);
        
        LOG_INF("This TX NET Core");
        

	while (1) {

           k_msleep(1000);
        }
} 

However, in actual operation, the IPC interrupt of NETCORE is not triggered. Is there a problem with my operation?

Parents Reply
  • Thank you very much for pointing out your mistakes.
    I added the entire following statement to both appcore and NETCORE:
    IRQ_CONNECT(IPC_IRQn, 1, ipc_event_handler, 0, 0);
    The interrupt is still not generated.
    What method can I use to confirm that the IPC sending of appcore is valid and the interrupt receiving of NETCORE is successful? What more mistakes did I fail to notice?
Children
Related