Source code for platypush.message.event.gpio
from typing import Union
from platypush.message.event import Event
[docs]
class GPIOEvent(Event):
    """
    Event triggered when the value on a GPIO PIN changes.
    """
[docs]
    def __init__(self, pin: Union[int, str], value: int, *args, **kwargs):
        """
        :param pin: PIN number or name.
        :param value: Current value of the PIN.
        """
        super().__init__(*args, pin=pin, value=value, **kwargs)
