Waveshare e-paper displays with SPI

@jtknep,

thank you for the feedback!

I have found out what is wrong with compilation for ESP32 Dev Module.

The ESP32 processor hangs on a second call to Serial.begin(115200) when compiled for ESP32 Dev Module.

// SerialBeginTwice test by Jean-Marc Zingg
//
// Purpose: test issue with ESP32 compiled for ESP32 Dev Module

void setup()
{
  Serial.begin(115200);
  delay(100);
  Serial.println("going to call Serial.begin(115200); a second time. Should tell success ...");
  delay(100);
  Serial.begin(115200);
  delay(100);
  Serial.println("... success, returned from second call to Serial.begin(115200); Bye and out.");
  delay(100);
}

void loop() {}

I verified this on a ESP32 Dev Module clone, on a Wemos LOLIN32 Lite, and on the Waveshare e-Paper ESP32 Driver Board.

The GxEPD2 examples call Serial.begin(115200) in setup() to Serial.print("setup"), and again in display.init(115200).

The example GxEPD2_WS_ESP32_Driver.ino with GDEM029T94 works ok if compiled for WEMOS LOLIN32.
(I first had an issue with garbage during partial update, because I had selected GxEPD2_3C instead of GxEPD2_BW).

The display class and the driver class need to correspond for monochrome or 3-color.
I don't see an easy way to check during compile time. Maybe I should add a warning diagnostic at runtime.

Jean-Marc