Not sure if I am making the right display selection. The chip I am using is a ESP-WROOM-32. I only made 3 changes in GxEPD2_display_selection_new_style.h:
Comment out this
//#define GxEPD2_DISPLAY_CLASS GxEPD2_BW
Uncomment this
#define GxEPD2_DISPLAY_CLASS GxEPD2_7C
Uncomment this
#define GxEPD2_DRIVER_CLASS GxEPD2_565c // Waveshare 5.65" 7-color
Also, as it was working with the Waveshare example, and some of the pins are not exposed in my ESP32 board, I followed the wiring in the Waveshare manual:
Comment out this
//GxEPD2_DISPLAY_CLASS<GxEPD2_DRIVER_CLASS, MAX_HEIGHT(GxEPD2_DRIVER_CLASS)> display(GxEPD2_DRIVER_CLASS(/*CS=5*/ EPD_CS, /*DC=*/ 17, /*RST=*/ 16, /*BUSY=*/ 4)); // my suggested wiring and proto board
Uncomment this
GxEPD2_DISPLAY_CLASS<GxEPD2_DRIVER_CLASS, MAX_HEIGHT(GxEPD2_DRIVER_CLASS)> display(GxEPD2_DRIVER_CLASS(/*CS=*/ 15, /*DC=*/ 27, /*RST=*/ 26, /*BUSY=*/ 25)); // Waveshare ESP32 Driver Board
Did some further testing and here are my observations:
Added a Serial.println statement at the beginning of setup(). The log line is not printed.
When I completely disconnect the monitor and boot just the ESP32 board, it entered setup() and also helloWorld().
Any idea on what might went wrong is highly appreciated!
Hi @ZinggJM , thanks for your prompt response, your comment enlightened me.
If my setup works with the Waveshare example which is designed to work with the Waveshare ESP32 Driver Board, then I should be using the Waveshare ESP32 configuration even though my ESP32 board is not from Waveshare.
So I tried the GxEPD2_WS_ESP32_Driver example. The display is now going full black and then full white in a loop. This is what I am getting from the serial, also keep looping:
I also tried uncommenting #define USE_HSPI_FOR_EPD in GxEPD2_display_selection.h in the GxEPD2_HelloWorld example, but still observing the behavior in #1.
@nkhin , thank you for the details and the picture.
I will need to retest with this display, first with my proto board with my standard suggested wiring, then with the wiring you reported. Clever idea to use angle pin connectors, I will do the same.
I don't understand why you can't use the suggested wiring. Your board looks quite usual, except for the cooling head.
This is strange. Are there exceptions reported in between?
In a next step I may need the exact code of the example you use; all files posted in a zip-file.
But first I need to check if something went wrong with my current release.
-jz-
Thank you for looking into this @ZinggJM , please let me know if there is anything I can test from my side.
I am working on a photo frame-like project, so trying to squeeze all the components in a tight space.
You are suggesting RST -> 0 for "ESP32 Dev Module", but I do not see a D0 on my board. Same for the other suggestion that uses RST -> 16, there is no D16 marked on the board. Maybe it's just labeled differently but I am not familiar with wiring, I am more of a software person
I have a couple of these heat sinks lying around, so I am sticking one to every ESP32 board I have. I don't think it's a temperature issue, it's not even working at bootup.
Thank you. I have found one error in this driver class, but there seems to be another one.
It's Sunday and lots of sport on TV now. Please be patient.
-jz-
This is not a suggestion, it is how the FPC connector is wired.
D0 is missing on many boards, as it is connected to the BOOT switch. I miss it, for a connection during program upload.
The error found makes all buffered graphics displays fail on this display.
With the fix they work, except the first one. So still no "Hello World!".
But you can try to add these two lines at the end of _InitDisplay:
_PowerOn();
_init_display_done = true;
I have pinpointed the other error. Should get fixed and tested tomorrow afternoon CET.
Hey @ZinggJM Sorry I was having a super busy week, I spent most of my time in the air.
I saw the library in Arduino has been updated to v1.5.5 so I used that directly. Confirmed that it is working perfectly. Thank you so much for your great work!
I just have 2 questions:
You mentioned:
Does it mean I cannot use the suggested wiring on this board?
The ESP32 board I am using is not from Waveshare but it only works with #define USE_HSPI_FOR_EPD. How do I tell when this is needed and when not?
I just try to give a short answer, as I am short of time.
I still don't know why you need a different wiring than the suggested one:
// mapping suggestion for ESP32, e.g. LOLIN32, see .../variants/.../pins_arduino.h for your board
// NOTE: there are variants with different pins for SPI ! CHECK SPI PINS OF YOUR BOARD
// BUSY -> 4, RST -> 16, DC -> 17, CS -> SS(5), CLK -> SCK(18), DIN -> MOSI(23), GND -> GND, 3.3V -> 3.3V
This wiring doesn't use D0.
If you need to use different pins for the SPI connection, different than the default HW SPI pins of the board you compile for, then you have two options, assuming standard ESP32:
you can remap the pins of the standard VSPI channel, by preselection using SPI.begin(...).
you can use the other HW SPI channel HSPI, by creating an instance for it and preselecting its pins.
All other pins to the e-paper panel can be chosen as you like, you just need to adapt the constructor parameters to your wiring. And watch out for strapping pins (boot mode issues).
-jz-