Skip to content

feat: add EP29Rv2_128x296 2.9" B/W/R panel (GDEM029C90, SSD1680) - #37

Open
grzegorzpuk-cpu wants to merge 1 commit into
bitbank2:mainfrom
grzegorzpuk-cpu:feat/add-ep29rv2-128x296
Open

feat: add EP29Rv2_128x296 2.9" B/W/R panel (GDEM029C90, SSD1680)#37
grzegorzpuk-cpu wants to merge 1 commit into
bitbank2:mainfrom
grzegorzpuk-cpu:feat/add-ep29rv2-128x296

Conversation

@grzegorzpuk-cpu

Copy link
Copy Markdown

Add EP29Rv2_128x296: 2.9" 128x296 B/W/R (GDEM029C90, SSD1680)

Summary

Adds a new panel type EP29Rv2_128x296 for the 2.9" 128x296 Black/White/Red
e-paper display (GoodDisplay GDEM029C90, SSD1680 controller). The init
sequence follows the proven GxEPD2 GxEPD2_290_C90c driver, which drives the
same panel correctly.

This is a purely additive change: the existing EP29R_128x296 and
EP26R_152x296 entries are left untouched.

Changes

src/bb_epaper.h

  • New enum value EP29Rv2_128x296 added just before EP_PANEL_COUNT.

src/bb_ep.inl

  1. New init sequence epd29rv2_init_sequence_full, matching
    GxEPD2_290_C90c::_InitDisplay():
    • 0x21 (Display Update Control 1) sent with 2 data bytes
      (0x00, 0x80) — the SSD1680 expects 2 bytes here; sending only 1
      desynchronises the rest of the init sequence
    • 0x3C border waveform = 0x05
    • RAM X end = 0x0F (128 px), RAM Y end = 0x0127 (296 rows)
    • RAM Y counter starts at 0
  2. New panelDefs[] entry:
    {128, 296, 0, epd29rv2_init_sequence_full, NULL, NULL, BBEP_3COLOR, BBEP_CHIP_SSD16xx, u8Colors_3clr}
  3. bbepRefresh(): special case for EP29Rv2_128x296 using display update
    control value 0xF7 (full LUT refresh, same as GxEPD2_290_C90c
    _Update_Full()), instead of the default 3-color 0xC7.

Why not reuse EP29R_128x296?

EP29R_128x296 exists but its init sequence has issues on this panel:

  • 0x21 sent with only 1 data byte (SSD1680 requires 2)
  • master activation (0x20) commented out
  • RAM Y counter initialised to the last row instead of 0

Those are left as-is to avoid regressions for anyone currently using
EP29R_128x296; the new panel type provides a correct, tested path for
GDEM029C90.

Tested

  • Hardware: WeAct Studio ESP32-C3 + 2.9" 128x296 B/W/R panel (GDEM029C90)
  • Pins: CS=7, DC=9, RES=8, BUSY=5, MOSI=6, SCLK=4
  • Full-screen black/white/red fills: correct, no Y offset, no garbage rows
  • Alternating black/red text lines across the whole display: correct
  • Text + circles + bitmap (three_color example content, rotation 270): correct

Usage

BBEPAPER bbep(EP29Rv2_128x296);

Add new panel type EP29Rv2_128x296 for the 2.9" 128x296 Black/White/Red
display (GoodDisplay GDEM029C90, SSD1680 controller). Init sequence and
refresh match the proven GxEPD2_290_C90c driver:
- 0x21 (Display Update Control 1) with 2 data bytes (0x00 0x80) - SSD1680
  requires 2 bytes here, sending 1 desynchronises the init sequence
- 0x3C border waveform 0x05, RAM X end 0x0F (128px), RAM Y end 0x0127
- RAM Y counter starts at 0
- refresh uses 0xF7 (full LUT) like GxEPD2_290_C90c _Update_Full()

Purely additive: existing EP29R_128x296 and EP26R_152x296 untouched.
@grzegorzpuk-cpu

Copy link
Copy Markdown
Author
3a 2a 1a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant