Platform/ECM3532/DSP/hw/csp/ecm3532/nxp/src/int_controller.c
/*
Configure which edge triggers several hardware interrupt:
    - Address where the Interrupt Controller is mapped: p_intctrl.
    - Bitmask for the hardware interrupts to be configured: interrupt_bitmask.
    - Triggering edge (rising or falling): edge.
*/
Configure which edge triggers several hardware interrupt:
Address where the Interrupt Controller is mapped: p_intctrl.
Bitmask for the hardware interrupts to be configured: interrupt_bitmask.
Triggering edge (rising or falling): edge.
Configure which edge triggers several hardware interrupt : Address where the Interrupt Controller is mapped : p_intctrl . Bitmask for the hardware interrupts to be configured : interrupt_bitmask . Triggering edge ( rising or falling ) : edge .
intctrl_err_T intctrl_setPolarity_bitmask(p_hw_intctrl_reg_T p_intctrl, bitmask_T int_bitmask, intctrl_edge_T edge)
{
    if (p_intctrl->enable & int_bitmask)
    {
        return INTCTRL_ENABLED_INT_ERR;
    }
    bitmask_T edge_mask = (edge == INTCTRL_FALLING_EDGE)? 0xffffff : 0x000000;
    p_intctrl->polarity &= (~int_bitmask);
    p_intctrl->polarity |= (int_bitmask & edge_mask);
    return INTCTRL_SUCCESS;
}
intctrl_err_T intctrl_setPolarity_bitmask ( p_hw_intctrl_reg_T p_intctrl , bitmask_T int_bitmask , intctrl_edge_T edge ) { if ( p_intctrl -> enable & int_bitmask ) { return INTCTRL_ENABLED_INT_ERR ; } bitmask_T edge_mask = ( edge == INTCTRL_FALLING_EDGE ) ? 0xffffff : 0x000000 ; p_intctrl -> polarity &= ( ~ int_bitmask ) ; p_intctrl -> polarity |= ( int_bitmask & edge_mask ) ; return INTCTRL_SUCCESS ; }
Configure which edge triggers several hardware interrupt:
 Address where the Interrupt Controller is mapped: p_intctrl.
Configure which edge triggers several hardware interrupt : Address where the Interrupt Controller is mapped : p_intctrl .
/* clear the value */ /* set it to the new value */