mirror of
https://github.com/esphome/esphome.git
synced 2025-10-17 01:03:46 +01:00
[mipi_spi] Rotation fixes (#11226)
This commit is contained in:
@@ -69,7 +69,7 @@ def run_schema_validation(config: ConfigType) -> None:
|
||||
{
|
||||
"id": "display_id",
|
||||
"model": "custom",
|
||||
"dimensions": {"width": 320, "height": 240},
|
||||
"dimensions": {"width": 260, "height": 260},
|
||||
"draw_rounding": 13,
|
||||
"init_sequence": [[0xA0, 0x01]],
|
||||
},
|
||||
@@ -336,7 +336,7 @@ def test_native_generation(
|
||||
|
||||
main_cpp = generate_main(component_fixture_path("native.yaml"))
|
||||
assert (
|
||||
"mipi_spi::MipiSpiBuffer<uint16_t, mipi_spi::PIXEL_MODE_16, true, mipi_spi::PIXEL_MODE_16, mipi_spi::BUS_TYPE_QUAD, 360, 360, 0, 1, display::DISPLAY_ROTATION_0_DEGREES, 1>()"
|
||||
"mipi_spi::MipiSpiBuffer<uint16_t, mipi_spi::PIXEL_MODE_16, true, mipi_spi::PIXEL_MODE_16, mipi_spi::BUS_TYPE_QUAD, 360, 360, 0, 1, display::DISPLAY_ROTATION_0_DEGREES, 1, 1>()"
|
||||
in main_cpp
|
||||
)
|
||||
assert "set_init_sequence({240, 1, 8, 242" in main_cpp
|
||||
|
@@ -7,8 +7,8 @@ display:
|
||||
id: ili9xxx_display
|
||||
model: GC9A01A
|
||||
invert_colors: True
|
||||
cs_pin: 10
|
||||
dc_pin: 6
|
||||
cs_pin: 11
|
||||
dc_pin: 7
|
||||
pages:
|
||||
- id: page1
|
||||
lambda: |-
|
||||
|
@@ -10,7 +10,7 @@ display:
|
||||
invert_colors: true
|
||||
show_test_card: true
|
||||
spi_mode: mode0
|
||||
draw_rounding: 8
|
||||
draw_rounding: 4
|
||||
use_axis_flips: true
|
||||
init_sequence:
|
||||
- [0xd0, 1, 2, 3]
|
||||
|
@@ -1,7 +1,7 @@
|
||||
substitutions:
|
||||
dc_pin: GPIO14
|
||||
cs_pin: GPIO13
|
||||
enable_pin: GPIO16
|
||||
enable_pin: GPIO17
|
||||
reset_pin: GPIO20
|
||||
|
||||
packages:
|
||||
|
Reference in New Issue
Block a user