Source code for caspia.meadow.services.fan

from caspia.meadow.value import InRange

from .base import Characteristic, ServiceBase


[docs]class FanBase(ServiceBase): """ Represents a fan. """ type = 'fan' is_on = Characteristic('bool', 'RWN') toggle = Characteristic('void', 'W') optional = {'speed'} speed = Characteristic('float', 'RWN', validate=InRange(0, 1))