FreeRTOS/Demo/Safer_Interrupts_M33F_NXP_LPC55S69_MCUXpresso/NXP_Code/drivers/fsl_pint.c
/*!
 * @brief	Clear all pin interrupts status only when pins were triggered by edge-sensitive.

 * This function clears the status of all pin interrupts.
 *
 * @param base Base address of the PINT peripheral.
 *
 * @retval None.
 */
@brief       Clear all pin interrupts status only when pins were triggered by edge-sensitive.
This function clears the status of all pin interrupts.

@param base Base address of the PINT peripheral.

@retval None.
@brief Clear all pin interrupts status only when pins were triggered by edge - sensitive . This function clears the status of all pin interrupts . @param base Base address of the PINT peripheral . @retval None .
void PINT_PinInterruptClrStatusAll(PINT_Type *base)
{
    uint32_t pinIntMode   = 0;
    uint32_t pinIntStatus = 0;
    uint32_t pinIntCount  = 0;
    uint32_t mask         = 0;
    uint32_t i;
    if (base == PINT)
    {
        pinIntCount = (uint32_t)FSL_FEATURE_PINT_NUMBER_OF_CONNECTED_OUTPUTS;
    }
    else
    {
#if (defined(FSL_FEATURE_SECPINT_NUMBER_OF_CONNECTED_OUTPUTS) && FSL_FEATURE_SECPINT_NUMBER_OF_CONNECTED_OUTPUTS)
        pinIntCount = (uint32_t)FSL_FEATURE_SECPINT_NUMBER_OF_CONNECTED_OUTPUTS;
#endif 
    }
    for (i = 0; i < pinIntCount; i++)
    {
        pinIntMode   = base->ISEL & (1UL << i);
        pinIntStatus = base->IST & (1UL << i);
        if ((pinIntMode == 0x0UL) && (pinIntStatus != 0x0UL))
        {
            mask |= 1UL << i;
        }
    }
    base->IST = mask;
}
void PINT_PinInterruptClrStatusAll ( PINT_Type * base ) { uint32_t pinIntMode = 0 ; uint32_t pinIntStatus = 0 ; uint32_t pinIntCount = 0 ; uint32_t mask = 0 ; uint32_t i ; if ( base == PINT ) { pinIntCount = ( uint32_t ) FSL_FEATURE_PINT_NUMBER_OF_CONNECTED_OUTPUTS ; } else { #if ( defined ( FSL_FEATURE_SECPINT_NUMBER_OF_CONNECTED_OUTPUTS ) && FSL_FEATURE_SECPINT_NUMBER_OF_CONNECTED_OUTPUTS ) pinIntCount = ( uint32_t ) FSL_FEATURE_SECPINT_NUMBER_OF_CONNECTED_OUTPUTS ; #endif } for ( i = 0 ; i < pinIntCount ; i ++ ) { pinIntMode = base -> ISEL & ( 1UL << i ) ; pinIntStatus = base -> IST & ( 1UL << i ) ; if ( ( pinIntMode == 0x0UL ) && ( pinIntStatus != 0x0UL ) ) { mask |= 1UL << i ; } } base -> IST = mask ; }
@brief       Clear all pin interrupts status only when pins were triggered by edge-sensitive.
@brief Clear all pin interrupts status only when pins were triggered by edge - sensitive .
/* FSL_FEATURE_SECPINT_NUMBER_OF_CONNECTED_OUTPUTS */ /* Edge sensitive and pin interrupt that is currently requesting an interrupt. */