pifacecommon/interrupts.py
def set_gpio_interrupt_edge(edge='falling'):
    """Set the interrupt edge on the userspace GPIO pin.

    :param edge: The interrupt edge ('none', 'falling', 'rising').
    :type edge: string
    """
    # we're only interested in the falling edge (1 -> 0)
    start_time = time.time()
    time_limit = start_time + FILE_IO_TIMEOUT
    while time.time() < time_limit:
        try:
            with open(GPIO_INTERRUPT_DEVICE_EDGE, 'w') as gpio_edge:
                gpio_edge.write(edge)
                return
        except IOError:
            pass
def set_gpio_interrupt_edge(edge='falling'):
    # we're only interested in the falling edge (1 -> 0)
    start_time = time.time()
    time_limit = start_time + FILE_IO_TIMEOUT
    while time.time() < time_limit:
        try:
            with open(GPIO_INTERRUPT_DEVICE_EDGE, 'w') as gpio_edge:
                gpio_edge.write(edge)
                return
        except IOError:
            pass
def set_gpio_interrupt_edge ( edge = 'falling' ) : # we're only interested in the falling edge (1 -> 0) start_time = time . time ( ) time_limit = start_time + FILE_IO_TIMEOUT while time . time ( ) < time_limit : try : with open ( GPIO_INTERRUPT_DEVICE_EDGE , 'w' ) as gpio_edge : gpio_edge . write ( edge ) return except IOError : pass
Set the interrupt edge on the userspace GPIO pin.

    :param edge: The interrupt edge ('none', 'falling', 'rising').
    :type edge: string
Set the interrupt edge on the userspace GPIO pin .