Fixes esphomelib#72

This commit is contained in:
Otto Winter 2018-06-08 20:32:53 +02:00
parent 68fa7489a2
commit 0be29d27d5
No known key found for this signature in database
GPG key ID: DB66C0BE6013F97E

View file

@ -21,7 +21,7 @@ FLOAT_OUTPUT_SCHEMA = BINARY_OUTPUT_SCHEMA.extend({
output_ns = esphomelib_ns.namespace('output')
def setup_output_platform(obj, config, skip_power_supply=False):
def setup_output_platform_(obj, config, skip_power_supply=False):
if CONF_INVERTED in config:
add(obj.set_inverted(config[CONF_INVERTED]))
if not skip_power_supply and CONF_POWER_SUPPLY in config:
@ -33,4 +33,9 @@ def setup_output_platform(obj, config, skip_power_supply=False):
add(obj.set_max_power(config[CONF_MAX_POWER]))
def setup_output_platform(obj, config, skip_power_supply=False):
for _ in setup_output_platform_(obj, config, skip_power_supply):
yield
BUILD_FLAGS = '-DUSE_OUTPUT'