예제 #1
0
 def __init__(
     self,
     host: str,
     protocol: "TPLinkSmartHomeProtocol" = None,
     context: str = None,
     cache_ttl: int = 3,
 ) -> None:
     SmartDevice.__init__(self, host, protocol, context, cache_ttl)
     self.emeter_type = "emeter"
     self._device_type = DeviceType.Plug
예제 #2
0
 def __init__(
     self,
     host: str,
     protocol: TPLinkSmartHomeProtocol = None,
     context: str = None,
     cache_ttl: int = 3,
 ) -> None:
     SmartDevice.__init__(
         self, host=host, protocol=protocol, context=context, cache_ttl=cache_ttl
     )
     self.emeter_type = "smartlife.iot.common.emeter"
     self._device_type = DeviceType.Bulb
예제 #3
0
    def __init__(self,
                 host: str,
                 protocol: 'TPLinkSmartHomeProtocol' = None,
                 context: str = None) -> None:
        SmartDevice.__init__(self, host, protocol, context)
        self._type = "emeter"

        #Kaithem Project Customizations to protect the relay_state
        #from wearing out by backing off if we repeat too often

        self.currentDelay = 0.05
        self.lastTransition = 0
예제 #4
0
 def __init__(self,
              host: str,
              protocol: 'TPLinkSmartHomeProtocol' = None) -> None:
     SmartDevice.__init__(self, host, protocol)
     self.emeter_type = "smartlife.iot.common.emeter"
예제 #5
0
 def __init__(self,
              ip_address: str,
              protocol: 'TPLinkSmartHomeProtocol' = None) -> None:
     SmartDevice.__init__(self, ip_address, protocol)
     self.emeter_type = "smartlife.iot.common.emeter"
     self.emeter_units = True
예제 #6
0
 def __init__(self, ip_address, protocol=None):
     SmartDevice.__init__(self, ip_address, protocol)
     self.emeter_type = "smartlife.iot.common.emeter"
     self.emeter_units = True
예제 #7
0
 def __init__(self,
              ip_address: str,
              protocol: 'TPLinkSmartHomeProtocol' = None) -> None:
     SmartDevice.__init__(self, ip_address, protocol)
     self.emeter_type = "emeter"
     self.emeter_units = False
예제 #8
0
 def __init__(self,
              host: str,
              protocol: 'TPLinkSmartHomeProtocol' = None,
              context: str = None) -> None:
     SmartDevice.__init__(self, host, protocol, context)
     self._type = "emeter"
예제 #9
0
 def __init__(self, ip_address, protocol=None):
     SmartDevice.__init__(self, ip_address, protocol)
     self.emeter_type = "emeter"
     self.emeter_units = False
예제 #10
0
 def __init__(self,
              host: str,
              protocol: 'TPLinkSmartHomeProtocol' = None,
              context: str = None) -> None:
     SmartDevice.__init__(self, host, protocol, context)
     self._type = "emeter"