| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511 |
- // Display Library for SPI e-paper panels from Dalian Good Display and boards from Waveshare.
- // Requires HW SPI and Adafruit_GFX. Caution: these e-papers require 3.3V supply AND data lines!
- //
- // based on Demo Example from Good Display: http://www.e-paper-display.com/download_list/downloadcategoryid=34&isMode=false.html
- // Controller: IL91874 : http://www.e-paper-display.com/download_detail/downloadsId=539.html
- //
- // Author: Jean-Marc Zingg
- //
- // Version: see library.properties
- //
- // Library: https://github.com/ZinggJM/GxEPD2
- #include "GxEPD2_270.h"
- GxEPD2_270::GxEPD2_270(int8_t cs, int8_t dc, int8_t rst, int8_t busy) :
- GxEPD2_EPD(cs, dc, rst, busy, LOW, 10000000, WIDTH, HEIGHT, panel, hasColor, hasPartialUpdate, hasFastPartialUpdate)
- {
- }
- void GxEPD2_270::clearScreen(uint8_t value)
- {
- writeScreenBuffer(value);
- refresh(true);
- writeScreenBufferAgain(value);
- }
- void GxEPD2_270::writeScreenBuffer(uint8_t value)
- {
- _initial_write = false; // initial full screen buffer clean done
- if (!_using_partial_mode) _Init_Part();
- _writeCommand(0x13); // set current
- for (uint32_t i = 0; i < uint32_t(WIDTH) * uint32_t(HEIGHT) / 8; i++)
- {
- _writeData(value);
- }
- if (_initial_refresh) writeScreenBufferAgain(value); // init "old data"
- }
- void GxEPD2_270::writeScreenBufferAgain(uint8_t value)
- {
- if (!_using_partial_mode) _Init_Part();
- _setPartialRamArea(0x14, 0, 0, WIDTH, HEIGHT);
- for (uint32_t i = 0; i < uint32_t(WIDTH) * uint32_t(HEIGHT) / 8; i++)
- {
- _writeData(value);
- }
- }
- void GxEPD2_270::writeImage(const uint8_t bitmap[], int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- _writeImage(0x15, bitmap, x, y, w, h, invert, mirror_y, pgm);
- }
- void GxEPD2_270::writeImageAgain(const uint8_t bitmap[], int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- _writeImage(0x14, bitmap, x, y, w, h, invert, mirror_y, pgm);
- }
- void GxEPD2_270::_writeImage(uint8_t command, const uint8_t bitmap[], int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- if (_initial_write) writeScreenBuffer(); // initial full screen buffer clean
- delay(1); // yield() to avoid WDT on ESP8266 and ESP32
- int16_t wb = (w + 7) / 8; // width bytes, bitmaps are padded
- x -= x % 8; // byte boundary
- w = wb * 8; // byte boundary
- int16_t x1 = x < 0 ? 0 : x; // limit
- int16_t y1 = y < 0 ? 0 : y; // limit
- int16_t w1 = x + w < int16_t(WIDTH) ? w : int16_t(WIDTH) - x; // limit
- int16_t h1 = y + h < int16_t(HEIGHT) ? h : int16_t(HEIGHT) - y; // limit
- int16_t dx = x1 - x;
- int16_t dy = y1 - y;
- w1 -= dx;
- h1 -= dy;
- if ((w1 <= 0) || (h1 <= 0)) return;
- if (!_using_partial_mode) _Init_Part();
- _setPartialRamArea(command, x1, y1, w1, h1);
- for (int16_t i = 0; i < h1; i++)
- {
- for (int16_t j = 0; j < w1 / 8; j++)
- {
- uint8_t data;
- // use wb, h of bitmap for index!
- int16_t idx = mirror_y ? j + dx / 8 + ((h - 1 - (i + dy))) * wb : j + dx / 8 + (i + dy) * wb;
- if (pgm)
- {
- #if defined(__AVR) || defined(ESP8266) || defined(ESP32)
- data = pgm_read_byte(&bitmap[idx]);
- #else
- data = bitmap[idx];
- #endif
- }
- else
- {
- data = bitmap[idx];
- }
- if (invert) data = ~data;
- _writeData(data);
- }
- }
- delay(1); // yield() to avoid WDT on ESP8266 and ESP32
- }
- void GxEPD2_270::writeImagePart(const uint8_t bitmap[], int16_t x_part, int16_t y_part, int16_t w_bitmap, int16_t h_bitmap,
- int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- _writeImagePart(0x15, bitmap, x_part, y_part, w_bitmap, h_bitmap, x, y, w, h, invert, mirror_y, pgm);
- }
- void GxEPD2_270::writeImagePartAgain(const uint8_t bitmap[], int16_t x_part, int16_t y_part, int16_t w_bitmap, int16_t h_bitmap,
- int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- _writeImagePart(0x14, bitmap, x_part, y_part, w_bitmap, h_bitmap, x, y, w, h, invert, mirror_y, pgm);
- }
- void GxEPD2_270::_writeImagePart(uint8_t command, const uint8_t bitmap[], int16_t x_part, int16_t y_part, int16_t w_bitmap, int16_t h_bitmap,
- int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- if (_initial_write) writeScreenBuffer(); // initial full screen buffer clean
- delay(1); // yield() to avoid WDT on ESP8266 and ESP32
- if ((w_bitmap < 0) || (h_bitmap < 0) || (w < 0) || (h < 0)) return;
- if ((x_part < 0) || (x_part >= w_bitmap)) return;
- if ((y_part < 0) || (y_part >= h_bitmap)) return;
- int16_t wb_bitmap = (w_bitmap + 7) / 8; // width bytes, bitmaps are padded
- x_part -= x_part % 8; // byte boundary
- w = w_bitmap - x_part < w ? w_bitmap - x_part : w; // limit
- h = h_bitmap - y_part < h ? h_bitmap - y_part : h; // limit
- x -= x % 8; // byte boundary
- w = 8 * ((w + 7) / 8); // byte boundary, bitmaps are padded
- int16_t x1 = x < 0 ? 0 : x; // limit
- int16_t y1 = y < 0 ? 0 : y; // limit
- int16_t w1 = x + w < int16_t(WIDTH) ? w : int16_t(WIDTH) - x; // limit
- int16_t h1 = y + h < int16_t(HEIGHT) ? h : int16_t(HEIGHT) - y; // limit
- int16_t dx = x1 - x;
- int16_t dy = y1 - y;
- w1 -= dx;
- h1 -= dy;
- if ((w1 <= 0) || (h1 <= 0)) return;
- if (!_using_partial_mode) _Init_Part();
- _setPartialRamArea(command, x1, y1, w1, h1);
- for (int16_t i = 0; i < h1; i++)
- {
- for (int16_t j = 0; j < w1 / 8; j++)
- {
- uint8_t data;
- // use wb_bitmap, h_bitmap of bitmap for index!
- int16_t idx = mirror_y ? x_part / 8 + j + dx / 8 + ((h_bitmap - 1 - (y_part + i + dy))) * wb_bitmap : x_part / 8 + j + dx / 8 + (y_part + i + dy) * wb_bitmap;
- if (pgm)
- {
- #if defined(__AVR) || defined(ESP8266) || defined(ESP32)
- data = pgm_read_byte(&bitmap[idx]);
- #else
- data = bitmap[idx];
- #endif
- }
- else
- {
- data = bitmap[idx];
- }
- if (invert) data = ~data;
- _writeData(data);
- }
- }
- delay(1); // yield() to avoid WDT on ESP8266 and ESP32
- }
- void GxEPD2_270::writeImage(const uint8_t* black, const uint8_t* color, int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- if (black)
- {
- writeImage(black, x, y, w, h, invert, mirror_y, pgm);
- }
- }
- void GxEPD2_270::writeImagePart(const uint8_t* black, const uint8_t* color, int16_t x_part, int16_t y_part, int16_t w_bitmap, int16_t h_bitmap,
- int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- if (black)
- {
- writeImagePart(black, x_part, y_part, w_bitmap, h_bitmap, x, y, w, h, invert, mirror_y, pgm);
- }
- }
- void GxEPD2_270::writeNative(const uint8_t* data1, const uint8_t* data2, int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- if (data1)
- {
- writeImage(data1, x, y, w, h, invert, mirror_y, pgm);
- }
- }
- void GxEPD2_270::drawImage(const uint8_t bitmap[], int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- writeImage(bitmap, x, y, w, h, invert, mirror_y, pgm);
- refresh(x, y, w, h);
- writeImageAgain(bitmap, x, y, w, h, invert, mirror_y, pgm);
- }
- void GxEPD2_270::drawImagePart(const uint8_t bitmap[], int16_t x_part, int16_t y_part, int16_t w_bitmap, int16_t h_bitmap,
- int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- writeImagePart(bitmap, x_part, y_part, w_bitmap, h_bitmap, x, y, w, h, invert, mirror_y, pgm);
- refresh(x, y, w, h);
- writeImagePartAgain(bitmap, x_part, y_part, w_bitmap, h_bitmap, x, y, w, h, invert, mirror_y, pgm);
- }
- void GxEPD2_270::drawImage(const uint8_t* black, const uint8_t* color, int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- if (black)
- {
- drawImage(black, x, y, w, h, invert, mirror_y, pgm);
- }
- }
- void GxEPD2_270::drawImagePart(const uint8_t* black, const uint8_t* color, int16_t x_part, int16_t y_part, int16_t w_bitmap, int16_t h_bitmap,
- int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- if (black)
- {
- drawImagePart(black, x_part, y_part, w_bitmap, h_bitmap, x, y, w, h, invert, mirror_y, pgm);
- }
- }
- void GxEPD2_270::drawNative(const uint8_t* data1, const uint8_t* data2, int16_t x, int16_t y, int16_t w, int16_t h, bool invert, bool mirror_y, bool pgm)
- {
- if (data1)
- {
- drawImage(data1, x, y, w, h, invert, mirror_y, pgm);
- }
- }
- void GxEPD2_270::refresh(bool partial_update_mode)
- {
- if (partial_update_mode) refresh(0, 0, WIDTH, HEIGHT);
- else
- {
- if (_using_partial_mode) _Init_Full();
- _Update_Full();
- _initial_refresh = false; // initial full update done
- }
- }
- void GxEPD2_270::refresh(int16_t x, int16_t y, int16_t w, int16_t h)
- {
- if (_initial_refresh) return refresh(false); // initial update needs be full update
- x -= x % 8; // byte boundary
- w -= x % 8; // byte boundary
- int16_t x1 = x < 0 ? 0 : x; // limit
- int16_t y1 = y < 0 ? 0 : y; // limit
- int16_t w1 = x + w < int16_t(WIDTH) ? w : int16_t(WIDTH) - x; // limit
- int16_t h1 = y + h < int16_t(HEIGHT) ? h : int16_t(HEIGHT) - y; // limit
- w1 -= x1 - x;
- h1 -= y1 - y;
- _refreshWindow(x1, y1, w1, h1);
- _waitWhileBusy("refresh", partial_refresh_time);
- }
- void GxEPD2_270::powerOff(void)
- {
- _PowerOff();
- }
- void GxEPD2_270::hibernate()
- {
- _PowerOff();
- if (_rst >= 0)
- {
- _writeCommand(0x07); // deep sleep
- _writeData(0xA5); // check code
- _hibernating = true;
- }
- }
- void GxEPD2_270::_setPartialRamArea(uint8_t command, uint16_t x, uint16_t y, uint16_t w, uint16_t h)
- {
- w = (w + 7 + (x % 8)) & 0xfff8; // byte boundary exclusive (round up)
- _writeCommand(command);
- _writeData(x >> 8);
- _writeData(x & 0xf8);
- _writeData(y >> 8);
- _writeData(y & 0xff);
- _writeData(w >> 8);
- _writeData(w & 0xf8);
- _writeData(h >> 8);
- _writeData(h & 0xff);
- }
- void GxEPD2_270::_refreshWindow(uint16_t x, uint16_t y, uint16_t w, uint16_t h)
- {
- w = (w + 7 + (x % 8)) & 0xfff8; // byte boundary exclusive (round up)
- h = gx_uint16_min(h, 256); // strange controller error
- _writeCommand(0x16);
- _writeData(x >> 8);
- _writeData(x & 0xf8);
- _writeData(y >> 8);
- _writeData(y & 0xff);
- _writeData(w >> 8);
- _writeData(w & 0xf8);
- _writeData(h >> 8);
- _writeData(h & 0xff);
- }
- void GxEPD2_270::_PowerOn()
- {
- if (!_power_is_on)
- {
- _writeCommand(0x04);
- _waitWhileBusy("_PowerOn", power_on_time);
- }
- _power_is_on = true;
- }
- void GxEPD2_270::_PowerOff()
- {
- _writeCommand(0x02); // power off
- _waitWhileBusy("_PowerOff", power_off_time);
- _power_is_on = false;
- _using_partial_mode = false;
- }
- void GxEPD2_270::_InitDisplay()
- {
- if (_hibernating) _reset();
- _writeCommand(0x01); //POWER SETTING
- _writeData (0x03);
- _writeData (0x00);
- _writeData (0x2b);
- _writeData (0x2b);
- _writeCommand(0x06); //boost
- _writeData (0x07); //A
- _writeData (0x07); //B
- _writeData (0x17); //C
- _writeCommand(0x16);
- _writeData(0x00);
- //_writeCommand(0x04);
- //_waitWhileBusy("_wakeUp Power On");
- _writeCommand(0x00); //panel setting
- _writeData(0xbf); //KW-BF KWR-AF BWROTP 0f
- _writeCommand(0x30); //PLL setting
- _writeData (0x3a); //90 50HZ 3A 100HZ 29 150Hz 39 200HZ 31 171HZ
- _writeCommand(0x61); //resolution setting
- _writeData (0x00);
- _writeData (0xb0); //176
- _writeData (0x01);
- _writeData (0x08); //264
- _writeCommand(0x82); //vcom_DC setting
- _writeData (0x08); //0x28:-2.0V,0x12:-0.9V
- }
- //full screen update LUT
- const uint8_t GxEPD2_270::lut_20_vcomDC[] PROGMEM =
- {
- 0x00, 0x00,
- 0x00, 0x08, 0x00, 0x00, 0x00, 0x02,
- 0x60, 0x28, 0x28, 0x00, 0x00, 0x01,
- 0x00, 0x14, 0x00, 0x00, 0x00, 0x01,
- 0x00, 0x12, 0x12, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- const uint8_t GxEPD2_270::lut_21_ww[] PROGMEM =
- {
- 0x40, 0x08, 0x00, 0x00, 0x00, 0x02,
- 0x90, 0x28, 0x28, 0x00, 0x00, 0x01,
- 0x40, 0x14, 0x00, 0x00, 0x00, 0x01,
- 0xA0, 0x12, 0x12, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- const uint8_t GxEPD2_270::lut_22_bw[] PROGMEM =
- {
- 0x40, 0x08, 0x00, 0x00, 0x00, 0x02,
- 0x90, 0x28, 0x28, 0x00, 0x00, 0x01,
- 0x40, 0x14, 0x00, 0x00, 0x00, 0x01,
- 0xA0, 0x12, 0x12, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- const uint8_t GxEPD2_270::lut_23_wb[] PROGMEM =
- {
- 0x80, 0x08, 0x00, 0x00, 0x00, 0x02,
- 0x90, 0x28, 0x28, 0x00, 0x00, 0x01,
- 0x80, 0x14, 0x00, 0x00, 0x00, 0x01,
- 0x50, 0x12, 0x12, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- const uint8_t GxEPD2_270::lut_24_bb[] PROGMEM =
- {
- 0x80, 0x08, 0x00, 0x00, 0x00, 0x02,
- 0x90, 0x28, 0x28, 0x00, 0x00, 0x01,
- 0x80, 0x14, 0x00, 0x00, 0x00, 0x01,
- 0x50, 0x12, 0x12, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- //partial screen update LUT
- const uint8_t GxEPD2_270::lut_20_vcomDC_partial[] PROGMEM =
- {
- 0x00, 0x00,
- 0x00, 0x19, 0x01, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- const uint8_t GxEPD2_270::lut_21_ww_partial[] PROGMEM =
- {
- 0x00, 0x19, 0x01, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- const uint8_t GxEPD2_270::lut_22_bw_partial[] PROGMEM =
- {
- 0x80, 0x19, 0x01, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- const uint8_t GxEPD2_270::lut_23_wb_partial[] PROGMEM =
- {
- 0x40, 0x19, 0x01, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- const uint8_t GxEPD2_270::lut_24_bb_partial[] PROGMEM =
- {
- 0x00, 0x19, 0x01, 0x00, 0x00, 0x01,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- void GxEPD2_270::_Init_Full()
- {
- _InitDisplay();
- _writeCommand(0x50); //VCOM AND DATA INTERVAL SETTING
- _writeData(0x97); //WBmode:VBDF 17|D7 VBDW 97 VBDB 57 WBRmode:VBDF F7 VBDW 77 VBDB 37 VBDR B7
- _writeCommand(0x20);
- _writeDataPGM_sCS(lut_20_vcomDC, sizeof(lut_20_vcomDC));
- _writeCommand(0x21);
- _writeDataPGM_sCS(lut_21_ww, sizeof(lut_21_ww));
- _writeCommand(0x22);
- _writeDataPGM_sCS(lut_22_bw, sizeof(lut_22_bw));
- _writeCommand(0x23);
- _writeDataPGM_sCS(lut_23_wb, sizeof(lut_23_wb));
- _writeCommand(0x24);
- _writeDataPGM_sCS(lut_24_bb, sizeof(lut_24_bb));
- _PowerOn();
- _using_partial_mode = false;
- }
- void GxEPD2_270::_Init_Part()
- {
- _InitDisplay();
- _writeCommand(0x50); //VCOM AND DATA INTERVAL SETTING
- _writeData(0x17); //WBmode:VBDF 17|D7 VBDW 97 VBDB 57 WBRmode:VBDF F7 VBDW 77 VBDB 37 VBDR B7
- _writeCommand(0x20);
- _writeDataPGM_sCS(lut_20_vcomDC_partial, sizeof(lut_20_vcomDC_partial));
- _writeCommand(0x21);
- _writeDataPGM_sCS(lut_21_ww_partial, sizeof(lut_21_ww_partial));
- _writeCommand(0x22);
- _writeDataPGM_sCS(lut_22_bw_partial, sizeof(lut_22_bw_partial));
- _writeCommand(0x23);
- _writeDataPGM_sCS(lut_23_wb_partial, sizeof(lut_23_wb_partial));
- _writeCommand(0x24);
- _writeDataPGM_sCS(lut_24_bb_partial, sizeof(lut_24_bb_partial));
- _PowerOn();
- _using_partial_mode = true;
- }
- void GxEPD2_270::_Update_Full()
- {
- _writeCommand(0x12); //display refresh
- _waitWhileBusy("_Update_Full", full_refresh_time);
- }
- void GxEPD2_270::_Update_Part()
- {
- _writeCommand(0x12); //display refresh
- _waitWhileBusy("_Update_Part", partial_refresh_time);
- }
|