Fast BW differential update for GxEPD2_420c_Z21

Hello!
I am using GDEQ042Z21, which is a Waveshare 4.2inch 3-color BWR EPD. (It is a V2 display)
MCU: ESP-WROOM-32 Dev kit (Keeyes)
GxEPD2 v1.5.7

When I try to run the Fast BW partial update example, I get errors:

GxEPD2_3C<GxEPD2_420c_Z21, GxEPD2_420c_Z21::HEIGHT> \
display(GxEPD2_420c_Z21(/*CS=*/ 5, /*DC=*/ 17, /*RST=*/ 16, /*BUSY=*/ 4));

error.log

In file included from C:\Users\viraj\Downloads\GxEPD2-master\GxEPD2-master\examples\GxEPD2x_FastBlackWhiteOnColor\GxEPD2x_FastBlackWhiteOnColor.ino:21:
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h: In instantiation of 'void GxEPD2_3C<GxEPD2_Type, page_height>::displayWindowBW(uint16_t, uint16_t, uint16_t, uint16_t) [with GxEPD2_Type = GxEPD2_420c_Z21; short unsigned int page_height = 300; uint16_t = short unsigned int]':
C:\Users\viraj\Downloads\GxEPD2-master\GxEPD2-master\examples\GxEPD2x_FastBlackWhiteOnColor\GxEPD2x_FastBlackWhiteOnColor.ino:81:28: required from here
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:275:12: error: 'class GxEPD2_420c_Z21' has no member named 'writeImagePartNew'; did you mean 'writeImagePart'?
275 | epd2.writeImagePartNew(_black_buffer, x, y, GxEPD2_Type::WIDTH, _page_height, x, y, w, h);
| ~^~~~~~~~~~~~~
| writeImagePart
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:276:12: error: 'class GxEPD2_420c_Z21' has no member named 'refresh_bw'; did you mean 'refresh'?
276 | epd2.refresh_bw(x, y, w, h);
| ~^~~~~~
| refresh
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:277:12: error: 'class GxEPD2_420c_Z21' has no member named 'writeImagePartPrevious'; did you mean 'writeImagePartAgain'?
277 | epd2.writeImagePartPrevious(_black_buffer, x, y, GxEPD2_Type::WIDTH, _page_height, x, y, w, h);
| ~^~~~~~~~~~~~~~~~~~
| writeImagePartAgain
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h: In instantiation of 'bool GxEPD2_3C<GxEPD2_Type, page_height>::nextPageBW() [with GxEPD2_Type = GxEPD2_420c_Z21; short unsigned int page_height = 300]':
C:\Users\viraj\Downloads\GxEPD2-master\GxEPD2-master\examples\GxEPD2x_FastBlackWhiteOnColor\GxEPD2x_FastBlackWhiteOnColor.ino:93:30: required from here
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:389:16: error: 'class GxEPD2_420c_Z21' has no member named 'writeImageNew'; did you mean 'writeImage'?
389 | epd2.writeImageNew(_black_buffer, _pw_x, _pw_y, _pw_w, _pw_h);
| ~^~~~~~~~~
| writeImage
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:390:16: error: 'class GxEPD2_420c_Z21' has no member named 'refresh_bw'; did you mean 'refresh'?
390 | epd2.refresh_bw(_pw_x, _pw_y, _pw_w, _pw_h);
| ~^~~~~~
| refresh
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:391:16: error: 'class GxEPD2_420c_Z21' has no member named 'writeImagePrevious'
391 | epd2.writeImagePrevious(_black_buffer, _pw_x, _pw_y, _pw_w, _pw_h);
| ~^~~~~~~~~~~~~~
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:397:16: error: 'class GxEPD2_420c_Z21' has no member named 'writeImagePrevious'
397 | epd2.writeImagePrevious(_black_buffer, 0, 0, GxEPD2_Type::WIDTH, HEIGHT);
| ~^~~~~~~~~~~~~~
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:414:36: error: 'class GxEPD2_420c_Z21' has no member named 'writeImageNew'; did you mean 'writeImage'?
414 | if (!_second_phase) epd2.writeImageNew(_black_buffer, _pw_x, dest_ys, _pw_w, dest_ye - dest_ys);
| ~^~~~~~~~~
| writeImage
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:415:21: error: 'class GxEPD2_420c_Z21' has no member named 'writeImagePrevious'
415 | else epd2.writeImagePrevious(_black_buffer, _pw_x, dest_ys, _pw_w, dest_ye - dest_ys);
| ~^~~~~~~~~~~~~~
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:429:18: error: 'class GxEPD2_420c_Z21' has no member named 'refresh_bw'; did you mean 'refresh'?
429 | epd2.refresh_bw(_pw_x, _pw_y, _pw_w, _pw_h);
| ~^~~~~~
| refresh
c:\Users\viraj\OneDrive\Documents\Arduino\libraries\GxEPD2\src/GxEPD2_3C.h:442:19: error: 'class GxEPD2_420c_Z21' has no member named 'writeImagePrevious'
442 | else epd2.writeImagePrevious(_black_buffer, 0, page_ys, GxEPD2_Type::WIDTH, gx_uint16_min(_page_height, HEIGHT - page_ys));
| ~^~~~~~~~~~~~~~
exit status 1
Compilation error: exit status 1

I think the new value is available much sooner and then some redundant refreshes happen after, so that makes me wonder if this display also support the fast BW partial update: https://youtube.com/shorts/AobRAWrBTLc?feature=share

GxEPD2x_FastBlackWhiteOnColor.ino

// experimental example GxEPD2x_FastBlackWhiteOnColor.ino: differential refresh on capable 3-color panels

//GxEPD2_3C<GxEPD2_213_Z19c, GxEPD2_213_Z19c::HEIGHT> display(GxEPD2_213_Z19c(/*CS=5*/ SS, /*DC=*/ 17, /*RST=*/ 16, /*BUSY=*/ 4)); // GDEW0213Z19
//GxEPD2_3C<GxEPD2_290_Z13c, GxEPD2_290_Z13c::HEIGHT> display(GxEPD2_290_Z13c(/*CS=5*/ SS, /*DC=*/ 17, /*RST=*/ 16, /*BUSY=*/ 4)); // GDEH029Z13

These are the only driver classes currently supporting this feature.

Yes, I am aware. My question is - if this display supports Fast BW partial update then, can I make a feature request to extend the 420c_Z21 class?

You can. But I don't like requests. And I have no time for this anyway.

Please take note that most Arduino libraries are voluntary work. And adapt your style accordingly.
-jz-

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.