esphome / issues

Issue Tracker for ESPHome
https://esphome.io/
291 stars 34 forks source link

ESP32 hangs/closes after "saving preferences to flash" #4497

Closed mattwl closed 1 year ago

mattwl commented 1 year ago

The problem

Hello

I am very new to this - so excuse any obvious oversights.

I'm trying to get a Waveshare e-Paper Driverboard going for the first time. When compiling a very simple YAML (via OTA using ESPHome) it seems to successfully write, but then appears to hang after this point in the log:

[D][esp32.preferences:143]: Saving 1 preferences to flash: 0 cached, 1 written, 0 failed

I can't see any activity/change on the attached eInk display, though ESPHome Dashboard shows that the device is Online. Should I expect the logs to go any further than the above?

Thanks

M

Which version of ESPHome has the issue?

2023.4.4

What type of installation are you using?

Home Assistant Add-on

Which version of Home Assistant has the issue?

2023.04.1

What platform are you using?

ESP32

Board

e-Paper ES32 Driver Board (Waveshare)

Component causing the issue

No response

Example YAML snippet

esphome:
  name: epaper
  compile_process_limit: 1
  on_boot:
    - logger.log: "Initial sensor data received: Refreshing display..."

esp32:
  board: esp32dev

# Enable logging
logger:

# Enable Home Assistant API
api:
ota:

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password
  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: !secret weatherman_ap_ssid
    password: !secret weatherman_ap_password

# Include custom fonts
font:
  - file: 'fonts/GothamRnd-Bold.ttf'
    id: font1
    size: 35

# Pins for Waveshare ePaper ESP Board
spi:
  clk_pin: GPIO18
  mosi_pin: GPIO23

# Now render everything on the ePaper screen.
display:
  - platform: waveshare_epaper
    cs_pin: GPIO5
    dc_pin: GPIO17
    busy_pin: GPIO4
    reset_pin: GPIO16
    model: 7.50inV2
    rotation: 0°
    update_interval: 30s
    lambda: |
      it.print(10,10, id(font1), "E-Paper is awesome!");

Anything in the logs that might be useful for us?

INFO Waiting for result...
INFO OTA successful
INFO Successfully uploaded program.
INFO Starting log output from epaper.local using esphome API
INFO Successfully connected to epaper.local
[14:12:51][I][app:102]: ESPHome version 2023.4.4 compiled on May  7 2023, 14:10:47
[14:12:51][C][wifi:505]: WiFi:
[14:12:51][C][wifi:363]:   Local MAC: 94:B5:55:05:41:90
[14:12:51][C][wifi:364]:   SSID: [redacted]
[14:12:51][C][wifi:365]:   IP Address: 10.1.1.103
[14:12:51][C][wifi:367]:   BSSID: [redacted]
[14:12:51][C][wifi:368]:   Hostname: 'epaper'
[14:12:51][C][wifi:370]:   Signal strength: -55 dB ▂▄▆█
[14:12:51][C][wifi:374]:   Channel: 1
[14:12:51][C][wifi:375]:   Subnet: 255.255.255.0
[14:12:51][C][wifi:376]:   Gateway: 10.1.1.1
[14:12:51][C][wifi:377]:   DNS1: 10.1.1.1
[14:12:51][C][wifi:378]:   DNS2: 0.0.0.0
[14:12:51][C][logger:294]: Logger:
[14:12:51][C][logger:295]:   Level: DEBUG
[14:12:51][C][logger:296]:   Log Baud Rate: 115200
[14:12:51][C][logger:297]:   Hardware UART: UART0
[14:12:51][C][spi:101]: SPI bus:
[14:12:51][C][spi:102]:   CLK Pin: GPIO18
[14:12:51][C][spi:104]:   MOSI Pin: GPIO23
[14:12:51][C][spi:106]:   Using HW SPI: YES
[14:12:51][C][waveshare_epaper:1240]: Waveshare E-Paper
[14:12:51][C][waveshare_epaper:1240]:   Rotations: 0 °
[14:12:51][C][waveshare_epaper:1240]:   Dimensions: 800px x 480px
[14:12:51][C][waveshare_epaper:1241]:   Model: 7.5inV2rev2
[14:12:51][C][waveshare_epaper:1242]:   Reset Pin: GPIO16
[14:12:51][C][waveshare_epaper:1243]:   DC Pin: GPIO17
[14:12:51][C][waveshare_epaper:1244]:   Busy Pin: GPIO4
[14:12:51][C][waveshare_epaper:1245]:   Update Interval: 30.0s
[14:12:51][C][mdns:108]: mDNS:
[14:12:51][C][mdns:109]:   Hostname: epaper
[14:12:51][C][ota:093]: Over-The-Air Updates:
[14:12:51][C][ota:094]:   Address: epaper.local:3232
[14:12:51][C][api:138]: API Server:
[14:12:51][C][api:139]:   Address: epaper.local:6053
[14:12:51][C][api:143]:   Using noise encryption: NO
[14:17:43][I][ota:113]: Boot seems successful, resetting boot loop counter.
[14:17:43][D][esp32.preferences:114]: Saving 1 preferences to flash...
[14:17:43][D][esp32.preferences:143]: Saving 1 preferences to flash: 0 cached, 1 written, 0 failed

Additional information

No response

ssieb commented 1 year ago

github issues are not for support requests. Come to the discord server or ask on one of the forums. It hasn't hung, there's nothing else that would be logged. If the display isn't working, that's most likely an issue with the display config or wiring.