src/arch/socs/stm32f439/C/soc-exti.c
uint32_t soc_exti_get_pending_lines(uint8_t irq)
{
    switch (irq) {
        case EXTI0_IRQ:
            return get_reg_value(EXTI_PR, 0x1, 0);
            break;
        case EXTI1_IRQ:
            return get_reg_value(EXTI_PR, 0x1 << 1, 1);
            break;
        case EXTI2_IRQ:
            return get_reg_value(EXTI_PR, 0x1 << 2, 2);
            break;
        case EXTI3_IRQ:
            return get_reg_value(EXTI_PR, 0x1 << 3, 3);
            break;
        case EXTI4_IRQ:
            return get_reg_value(EXTI_PR, 0x1 << 4, 4);
            break;
        case EXTI9_5_IRQ:
            return get_reg_value(EXTI_PR, 0x1f << 5, 5);
            break;
        case EXTI15_10_IRQ:
            return get_reg_value(EXTI_PR, 0x3f << 10, 10);
            break;
        default:
            return 0;
    }
}
/*
 * Return the bit (or the bitfield) of the pending IT lines of the
 * EXTI for the corresponding IRQ
 */
Return the bit (or the bitfield) of the pending IT lines of the
EXTI for the corresponding IRQ
Return the bit ( or the bitfield ) of the pending IT lines of the EXTI for the corresponding IRQ
uint32_t soc_exti_get_pending_lines(uint8_t irq)
{
    switch (irq) {
        case EXTI0_IRQ:
            return get_reg_value(EXTI_PR, 0x1, 0);
            break;
        case EXTI1_IRQ:
            return get_reg_value(EXTI_PR, 0x1 << 1, 1);
            break;
        case EXTI2_IRQ:
            return get_reg_value(EXTI_PR, 0x1 << 2, 2);
            break;
        case EXTI3_IRQ:
            return get_reg_value(EXTI_PR, 0x1 << 3, 3);
            break;
        case EXTI4_IRQ:
            return get_reg_value(EXTI_PR, 0x1 << 4, 4);
            break;
        case EXTI9_5_IRQ:
            return get_reg_value(EXTI_PR, 0x1f << 5, 5);
            break;
        case EXTI15_10_IRQ:
            return get_reg_value(EXTI_PR, 0x3f << 10, 10);
            break;
        default:
            return 0;
    }
}
uint32_t soc_exti_get_pending_lines ( uint8_t irq ) { switch ( irq ) { case EXTI0_IRQ : return get_reg_value ( EXTI_PR , 0x1 , 0 ) ; break ; case EXTI1_IRQ : return get_reg_value ( EXTI_PR , 0x1 << 1 , 1 ) ; break ; case EXTI2_IRQ : return get_reg_value ( EXTI_PR , 0x1 << 2 , 2 ) ; break ; case EXTI3_IRQ : return get_reg_value ( EXTI_PR , 0x1 << 3 , 3 ) ; break ; case EXTI4_IRQ : return get_reg_value ( EXTI_PR , 0x1 << 4 , 4 ) ; break ; case EXTI9_5_IRQ : return get_reg_value ( EXTI_PR , 0x1f << 5 , 5 ) ; break ; case EXTI15_10_IRQ : return get_reg_value ( EXTI_PR , 0x3f << 10 , 10 ) ; break ; default : return 0 ; } }
Return the bit (or the bitfield) of the pending IT lines of the
 EXTI for the corresponding IRQ
Return the bit ( or the bitfield ) of the pending IT lines of the EXTI for the corresponding IRQ