In my pursuit to make the CALE displays as small as possible but also to learn how different boards interact with Epaper I got last week an Waveshare E-Ink ESP32 driver board.

Not all the boards need to use the default SPI GPIOs of the ESP32 and this was one of this cases. Opening the documentation, the first check was to see that Waveshare used this PINS:
#define PIN_SPI_SCK 13 // CLOCK ESP32 default 18 #define PIN_SPI_DIN 14 // MOSI ESP32 default: 23 #define PIN_SPI_CS 15 #define PIN_SPI_BUSY 25 #define PIN_SPI_RST 26 #define PIN_SPI_DC 27
So my first though was Ok nice but this won’t work per se using gxEPD library. Because this great library starts the SPI.begin() withouth parameters hence using ESP32 /ESP8266 default GPIOs for SPI communication. So what I did to test is very simple, I forked GxEPD:
https://github.com/martinberlin/GxEPD-config-spi.git
And updated this part of the library to use defines that can be injected using Platformio build_flags:
build_flags = -DCLK_GPIO=13 -DMOSI_GPIO=14 -DCS_GPIO=15
If we want to test it with CALE we can also use the same defines to reference the EInk wiring in lib/Config/Config.h
The party breaker
That’s 13 mA per hour. Unless I’m missing something and there is something big that needs to be switched of before deepsleep this EPD driver will eat your battery and your kids for dinner.So that was the low point of this test. If someone’s got a clue about this high consumption when sleeping please write something in the comments.
