'Turn the device off.'

def turn_off(self, **kwargs):

    if (ATTR_TRANSITION in kwargs):
        fade = int((kwargs[ATTR_TRANSITION] * 1000))
    else:
        fade = 0
    _LOGGER.debug('turn_off:    %s    %d', self._ip, fade)
    self._liffylights.set_power(self._ip, 0, fade)
