I’ve been unable to get my 2.9" black/white/red WeAct ePaper module (see here on AliExpress) working with ESPHome. Even just in black/white mode (I tried “model: 2.90in-b” and all the others). It’s frustrating, because it very nearly works: black text displays clearly, but the “red” colour is overlaid and the whole display keeps blinking and refreshing endlessly. It’s connected to an ESP32-C3.
My conclusion is not to use the displays with red because the refresh time of 20 seconds is just too long vs 5s for the black and white versions. But it would be nice if HA supported them.
If there’s anything else to try, please let me know!
Configuration here;
esphome:
name: adam2
friendly_name: adam2
esp32:
board: esp32-c3-devkitm-1
framework:
type: arduino
# Enable logging
logger:
# Enable Home Assistant API
api:
encryption:
key: "1234"
ota:
- platform: esphome
password: "1234"
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "Adam2 Fallback Hotspot"
password: "1234"
captive_portal:
font:
- file:
type: gfonts
family: Roboto
id: roboto_20
size: 20
extras: # Need to manually add support for the dollar symbol $
- file: "gfonts://Roboto"
glyphs: [$]
- file:
type: gfonts
family: Roboto
id: roboto_10
size: 10
- file: 'fonts/materialdesignicons-webfont.ttf'
id: mdi_wifi
size: 20
glyphs: [
# Wifi
'', # mdi-wifi-strength-alert-outline
'', # mdi-wifi-strength-1
'', # mdi-wifi-strength-2
'', # mdi-wifi-strength-3
'' # mdi-wifi-strength-4
]
time:
- platform: homeassistant
id: homeassistant_time
# Add the sensor from Home Assistant
sensor:
- platform: homeassistant
entity_id: sensor.exchange_rate_1_btc
id: bitcoin_price
- platform: wifi_signal
name: "WiFi Signal Sensor"
id: wifisignal
update_interval: 60s
spi:
clk_pin: 4 # SCK (SPI Clock) / SCL / CLK on the board - Green / Yellow
mosi_pin: 6 # MOSI (SPI Data Input) / SDA / DIN on the board - Yellow / Blue
display:
- platform: waveshare_epaper
model: 2.90inV2
cs_pin: 7 # CS (Chip Select) - Blue / Orange
dc_pin: 1 # D/C (Data/Command) - White / Green
busy_pin: 3 # BUSY (Busy signal) - Purple / Purple
reset_pin: 2 # RES (Reset) - Orange / White
rotation: 270
full_update_every: 1
update_interval: 30s
id: adam_epaper1
lambda: |-
ESP_LOGD("display", "Printing bitcoin price");
if (!isnan(id(bitcoin_price).state)) {
it.printf(10, 20, id(roboto_20), TextAlign::BASELINE_LEFT, "Bitcoin price: $%.0f", id(bitcoin_price).state);
} else {
it.printf(10, 20, id(roboto_20), TextAlign::BASELINE_LEFT, "Bitcoin price unavailable");
}
/* FOOTER */
it.strftime(200, 100, id(roboto_10), TextAlign::BASELINE_RIGHT , "Updated %H:%M %d/%b/%Y", id(homeassistant_time).now());
/* WiFi Signal Strength */
if(id(wifisignal).has_state()) {
int x = 260;
int y = 110;
if (id(wifisignal).state >= -50) {
//Excellent
it.print(x, y, id(mdi_wifi), TextAlign::BASELINE_CENTER, "");
ESP_LOGI("WiFi", "Exellent");
} else if (id(wifisignal).state >= -60) {
//Good
it.print(x, y, id(mdi_wifi), TextAlign::BASELINE_CENTER, "");
ESP_LOGI("WiFi", "Good");
} else if (id(wifisignal).state >= -75) {
//Fair
it.print(x, y, id(mdi_wifi), TextAlign::BASELINE_CENTER, "");
ESP_LOGI("WiFi", "Fair");
} else if (id(wifisignal).state >= -100) {
//Weak
it.print(x, y, id(mdi_wifi), TextAlign::BASELINE_CENTER, "");
ESP_LOGI("WiFi", "Weak");
} else {
//Unlikely working signal
it.print(x, y, id(mdi_wifi), TextAlign::BASELINE_CENTER, "");
ESP_LOGI("WiFi", "Unlikely");
}
}