            EventHandler.__init__(self)
            self.PIN = pin
            GPIO.setup(self.PIN, GPIO.IN)

        def cleanup(self):
            GPIO.cleanup(self.PIN)

        def check(self):
            if GPIO.input(self.PIN):
                self.fire()
