Do not require CS pin for ST7789V (#3888)

Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
This commit is contained in:
definitio 2022-10-12 22:26:28 +03:00 committed by GitHub
parent b34d24735a
commit 48a1797e72
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,7 +4,6 @@ from esphome import pins
from esphome.components import display, spi
from esphome.const import (
CONF_BACKLIGHT_PIN,
CONF_CS_PIN,
CONF_DC_PIN,
CONF_HEIGHT,
CONF_ID,
@ -69,7 +68,6 @@ CONFIG_SCHEMA = cv.All(
cv.Required(CONF_MODEL): ST7789V_MODEL,
cv.Required(CONF_RESET_PIN): pins.gpio_output_pin_schema,
cv.Required(CONF_DC_PIN): pins.gpio_output_pin_schema,
cv.Required(CONF_CS_PIN): pins.gpio_output_pin_schema,
cv.Optional(CONF_BACKLIGHT_PIN): pins.gpio_output_pin_schema,
cv.Optional(CONF_EIGHTBITCOLOR, default=False): cv.boolean,
cv.Optional(CONF_HEIGHT): cv.int_,
@ -79,7 +77,7 @@ CONFIG_SCHEMA = cv.All(
}
)
.extend(cv.polling_component_schema("5s"))
.extend(spi.spi_device_schema()),
.extend(spi.spi_device_schema(cs_pin_required=False)),
validate_st7789v,
)