Minimum 1 for full_update_every to prevent IntegerDivideByZero. (#6150)

This commit is contained in:
Ruben van Dijk 2024-01-27 21:15:14 +01:00 committed by GitHub
parent f2caf13d39
commit 23a9a704f3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -135,7 +135,7 @@ CONFIG_SCHEMA = cv.All(
cv.Required(CONF_MODEL): cv.one_of(*MODELS, lower=True),
cv.Optional(CONF_RESET_PIN): pins.gpio_output_pin_schema,
cv.Optional(CONF_BUSY_PIN): pins.gpio_input_pin_schema,
cv.Optional(CONF_FULL_UPDATE_EVERY): cv.uint32_t,
cv.Optional(CONF_FULL_UPDATE_EVERY): cv.int_range(min=1, max=4294967295),
cv.Optional(CONF_RESET_DURATION): cv.All(
cv.positive_time_period_milliseconds,
cv.Range(max=core.TimePeriod(milliseconds=500)),