Fix remote_transmitter wait time unit (#654)

Fixes https://github.com/esphome/issues/issues/485
This commit is contained in:
Otto Winter 2019-06-26 21:48:00 +02:00 committed by GitHub
parent 49f9ad66db
commit 82625a3080
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -88,7 +88,7 @@ def validate_repeat(value):
return cv.Schema({ return cv.Schema({
cv.Required(CONF_TIMES): cv.templatable(cv.positive_int), cv.Required(CONF_TIMES): cv.templatable(cv.positive_int),
cv.Optional(CONF_WAIT_TIME, default='10ms'): cv.Optional(CONF_WAIT_TIME, default='10ms'):
cv.templatable(cv.positive_time_period_milliseconds), cv.templatable(cv.positive_time_period_microseconds),
})(value) })(value)
return validate_repeat({CONF_TIMES: value}) return validate_repeat({CONF_TIMES: value})
@ -506,7 +506,7 @@ RC_SWITCH_TRANSMITTER = cv.Schema({
cv.Optional(CONF_REPEAT, default={CONF_TIMES: 5}): cv.Schema({ cv.Optional(CONF_REPEAT, default={CONF_TIMES: 5}): cv.Schema({
cv.Required(CONF_TIMES): cv.templatable(cv.positive_int), cv.Required(CONF_TIMES): cv.templatable(cv.positive_int),
cv.Optional(CONF_WAIT_TIME, default='10ms'): cv.Optional(CONF_WAIT_TIME, default='10ms'):
cv.templatable(cv.positive_time_period_milliseconds), cv.templatable(cv.positive_time_period_microseconds),
}), }),
}) })