Ejemplo n.º 1
0
def to_code(config):
    output = None
    for output in get_variable(config[CONF_OUTPUT]):
        yield
    rhs = App.make_binary_light(config[CONF_NAME], output)
    light_struct = variable(config[CONF_MAKE_ID], rhs)
    light.setup_light(light_struct.Pstate, light_struct.Pmqtt, config)
Ejemplo n.º 2
0
def to_code(config):
    output = get_variable(config[CONF_OUTPUT])
    rhs = App.make_binary_light(config[CONF_NAME], output)
    light_struct = variable('Application::MakeLight', config[CONF_ID], rhs)
    setup_mqtt_component(light_struct.Pmqtt, config)
    light.setup_light_component(light_struct.Pstate, config)