test_pattern_bar_ladder_diagonal.esp32-idf.yaml 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. # Canonical bench visual-check pattern, not a minimal smoke test like the
  2. # other fixtures in this directory. Scales to any panel via
  3. # it.get_width()/it.get_height(); each zone targets a specific bug class -
  4. # see claude/DESIGN.md's "Bench test pattern" section for the full
  5. # rationale. This is the actual pattern (previously only ever staged
  6. # on-device, never committed) whose row ladder + diagonal caught the
  7. # GDEY0579F51 row-interleave bug and confirmed the fix - see the
  8. # gxepd2-bench-validation-status memory.
  9. #
  10. # Wired here against GDEY0579F51 (4-color, dual-CS master+slave,
  11. # row_interleave: true) since that's the panel this pattern was built to
  12. # debug, but the lambda itself is panel-agnostic - copy it into any other
  13. # color-capable fixture's `lambda:` unchanged.
  14. esphome:
  15. name: gxepd2-test-pattern
  16. esp32:
  17. board: esp32dev
  18. framework:
  19. type: esp-idf
  20. external_components:
  21. - source:
  22. type: local
  23. path: ../components
  24. components: [gxepd2]
  25. spi:
  26. clk_pin: 18
  27. mosi_pin: 23
  28. logger:
  29. # gfonts:// is fetched by the builder at compile time - no local font file to
  30. # vendor. Used only for test_pattern()'s model-trailer label.
  31. font:
  32. - file: "gfonts://Roboto"
  33. id: panel_label_font
  34. size: 24
  35. display:
  36. - platform: gxepd2
  37. id: gxepd2_test
  38. model: GxEPD2_579c_GDEY0579F51
  39. cs_pin: 5
  40. dc_pin: 17
  41. reset_pin: 16
  42. busy_pin: 4
  43. name_font: panel_label_font
  44. update_interval: 60s
  45. # The whole pattern now lives in GxEPD2Display::test_pattern() (C++), so
  46. # it can read this panel's descriptor directly and scale the bar count,
  47. # ladder cycle and corner markers to the colors it can actually show -
  48. # the lambda just invokes it. See gxepd2_display.h for the zone rationale
  49. # that used to live in this block.
  50. lambda: |-
  51. id(gxepd2_test).test_pattern();