esphome-components icon indicating copy to clipboard operation
esphome-components copied to clipboard

eq3_v2 crashes on ESPHome 2021.12.0

Open dedors opened this issue 3 years ago • 8 comments

At least I think it's caused by eq3_v2 since that is the only thing running, and my other devices did update to 2021.12.0 with no problems.

[D][climate:381]: 'Thermostat EQ3 Schlofzimmer' - Sending state:
[D][climate:384]:   Mode: AUTO
[D][climate:395]:   Preset: HOME
[D][climate:410]:   Target Temperature: 12.00°C
[I][app:062]: setup() finished successfully!
[I][eq3:072]: Requesting ID of 1a220e5096...
[D][esp32_ble:104]: BT init done.
E (8066) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
E (8066) task_wdt:  - loopTask (CPU 1)
E (8066) task_wdt: Tasks currently running:
E (8066) task_wdt: CPU 0: IDLE0
E (8066) task_wdt: CPU 1: IDLE1
E (8066) task_wdt: Aborting.
abort() was called at PC 0x401b9f28 on core 0

ELF file SHA256: 0000000000000000

Backtrace: 0x4008f980:0x3ffbfdf0 0x4008fbfd:0x3ffbfe10 0x401b9f28:0x3ffbfe30 0x4008e029:0x3ffbfe50 0x401e4767:0x3ffbc100 0x401bb8b3:0x3ffbc120 0x40092421:0x3ffbc140 0x40090c72:0x3ffbc160

Rebooting...
ets Jun  8 2016 00:22:57

rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0018,len:4
load:0x3fff001c,len:1044
load:0x40078000,len:10124
load:0x40080400,len:5828
entry 0x400806a8
[E][esp32-hal-misc.c:111] disableCore1WDT(): Failed to remove Core 1 IDLE task from WDT

And then reboots.

My config

esphome:
  name: esp-gang
  platform: ESP32
  board: esp32doit-devkit-v1

wifi:
 *******
logger:

api:

ota:

external_components:
  - source: github://ayufan/esphome-components

time:
  - platform: sntp
    id: sntp_time

climate:
  - platform: eq3_v2
    id: thermostat_eq3_schlofzimmer
    name: Thermostat EQ3 Schlofzimmer
    mac_address: ************
    update_interval: 30min
    valve: # optional, allows to see valve state in %
      name: Thermostat EQ3 Schlofzimmer State
     # expire_after: 61min

switch:
  - platform: template
    name: "Thermostat EQ3 Schlofzimmer Refresh"
    lambda: "return false;"
    turn_on_action:
      - component.update: thermostat_eq3_schlofzimmer

A side note, the expire_after: entry gives a This option requires component mqtt. when compiling. I'm a bit confused as it already uses mqtt?

dedors avatar Dec 12 '21 05:12 dedors

I've updated to 2021.12.1 today and seeing the same behavior. All nodes that are not running eq3_v2 updated flawlessly, but the one with it gets the same error as posted above by @dedors.

After removing the external_component it compiled successfully. So I can confirm your thoughts about it.

Meaxl avatar Dec 16 '21 16:12 Meaxl

Same here. compilation is successful, but new firmware, once uploaded keeps crashing on start-up. From what I gather it happens right after initial BT query for the devices.

[16:25:42][I][eq3:086]: Requesting Schedule of 1a2214b9b1...
[16:25:44]E (9246) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
[16:25:44]E (9246) task_wdt:  - loopTask (CPU 1)
[16:25:44]E (9246) task_wdt: Tasks currently running:
[16:25:44]E (9246) task_wdt: CPU 0: IDLE0
[16:25:44]E (9246) task_wdt: CPU 1: IDLE1
[16:25:44]E (9246) task_wdt: Aborting.
[16:25:44]abort() was called at PC 0x401cad64 on core 0
[16:25:44]
[16:25:44]ELF file SHA256: 0000000000000000
[16:25:44]
[16:25:44]Backtrace: 0x4008f980:0x3ffbfe40 0x4008fbfd:0x3ffbfe60 0x401cad64:0x3ffbfe80 0x4008e029:0x3ffbfea0 0x401f752b:0x3ffbc160 0x401cd85f:0x3ffbc180 0x40092421:0x3ffbc1a0 0x40090c72:0x3ffbc1c0
[16:25:44]
[16:25:44]Rebooting...
[16:25:44]ets Jun  8 2016 00:22:57
[16:25:44]
[16:25:44]rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[16:25:44]configsip: 188777542, SPIWP:0xee
[16:25:44]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[16:25:44]mode:DIO, clock div:2
[16:25:44]load:0x3fff0018,len:4
[16:25:44]load:0x3fff001c,len:1044
[16:25:44]load:0x40078000,len:8896
[16:25:44]load:0x40080400,len:5828
[16:25:44]entry 0x400806ac
[16:25:45][E][esp32-hal-misc.c:111] disableCore1WDT(): Failed to remove Core 1 IDLE task from WDT
[16:25:45][I][logger:214]: Log initialized

jperquin avatar Dec 20 '21 15:12 jperquin

same issue

[18:04:05][W][ota:092]: Last Boot was an unhandled reset, will proceed to safe mode in 4 restarts
[18:04:05][C][mqtt:029]: Setting up MQTT...
[18:04:05][I][mqtt:174]: Connecting to MQTT...
[18:04:05][I][mqtt:214]: MQTT Connected!
[18:04:05][C][sntp:025]: Setting up SNTP...
[18:04:05][I][app:062]: setup() finished successfully!
[18:04:05][I][eq3:072]: Requesting ID of 1a220ebf78...
[18:04:05][D][esp32_ble:104]: BT init done.
[18:04:10][I][eq3:079]: ID of 1a220ebf78 succeeded.
[18:04:10][I][eq3:086]: Requesting Schedule of 1a220ebf78...
[18:04:10]E (9450) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
[18:04:10]E (9450) task_wdt:  - loopTask (CPU 1)
[18:04:10]E (9450) task_wdt: Tasks currently running:
[18:04:10]E (9450) task_wdt: CPU 0: IDLE0
[18:04:10]E (9450) task_wdt: CPU 1: IDLE1
[18:04:10]E (9450) task_wdt: Aborting.
[18:04:10]abort() was called at PC 0x401c5964 on core 0
[18:04:10]
[18:04:10]ELF file SHA256: 0000000000000000
[18:04:10]
[18:04:10]Backtrace: 0x4008f980:0x3ffbfe40 0x4008fbfd:0x3ffbfe60 0x401c5964:0x3ffbfe80 0x4008e029:0x3ffbfea0 0x401f1baf:0x3ffbc160 0x401c82df:0x3ffbc180 0x40092421:0x3ffbc1a0 0x40090c72:0x3ffbc1c0
WARNING Found stack trace! Trying to decode it
WARNING Decoded 0x4008f980: invoke_abort at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/esp32/panic.c:715
WARNING Decoded 0x4008fbfd: abort at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/esp32/panic.c:715
WARNING Decoded 0x401c5964: task_wdt_isr at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/esp32/task_wdt.c:252
WARNING Decoded 0x4008e029: _xt_lowint1 at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/freertos/xtensa_vectors.S:1154
WARNING Decoded 0x401f1baf: esp_pm_impl_waiti at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/esp32/pm_esp32.c:492
WARNING Decoded 0x401c82df: esp_vApplicationIdleHook at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/esp32/freertos_hooks.c:108
WARNING Decoded 0x40092421: prvIdleTask at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/freertos/tasks.c:3507
WARNING Decoded 0x40090c72: vPortTaskWrapper at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/freertos/port.c:355 (discriminator 1)
[18:04:10]
[18:04:10]Rebooting...
[18:04:10]ets Jun  8 2016 00:22:57
[18:04:10]
[18:04:10]rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[18:04:10]configsip: 0, SPIWP:0xee
[18:04:10]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[18:04:10]mode:DIO, clock div:2
[18:04:10]load:0x3fff0018,len:4
[18:04:10]load:0x3fff001c,len:1044
[18:04:10]load:0x40078000,len:10124
[18:04:10]load:0x40080400,len:5828
[18:04:10]entry 0x400806a8
[18:04:11][E][esp32-hal-misc.c:111] disableCore1WDT(): Failed to remove Core 1 IDLE task from WDT
[18:04:11][I][logger:214]: Log initialized

pikciu avatar Dec 22 '21 17:12 pikciu

Had another go with ESPHome v. 2022.2.3 and ESP32 keeps rebooting..

Would be nice if someone can have a look at the code. From what I can gather the only relevant changes from v 2021.11 to 2021.12 are these two: https://github.com/esphome/esphome/pull/2707 and https://github.com/esphome/esphome/pull/2801

jperquin avatar Feb 18 '22 12:02 jperquin

.. bump

jperquin avatar Apr 13 '22 12:04 jperquin

Not working on 2022.11.2

deviant-aut avatar Nov 24 '22 09:11 deviant-aut

The problem is with some kind of memory corruption happening somewhere likely. I noticed this at random and there's no a good explanation how to fix it.

ayufan avatar Jan 24 '23 10:01 ayufan

I can't get this running, either. My ESP32 just reboots constantly.

logger output when logging is enabled
[23:43:10][C][wifi:376]:   DNS1: 192.168.1.1
[23:43:10][C][wifi:377]:   DNS2: 0.0.0.0
[23:43:10][D][wifi:527]: Disabling AP...
[23:43:10][C][ota:093]: Over-The-Air Updates:
[23:43:10][C][ota:094]:   Address: eq3-relay.local:3232
[23:43:10][C][ota:097]:   Using Password.
[23:43:10][W][ota:103]: Last Boot was an unhandled reset, will proceed to safe mode in 3 restarts
[23:43:10][C][api:025]: Setting up Home Assistant API server...
[23:43:10][I][app:062]: setup() finished successfully!
[23:43:10][I][eq3:072]: Requesting ID of [redacted]...
[23:43:11][D][esp32_ble:104]: BT init done.
[23:43:15]E (18457) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
[23:43:15]E (18457) task_wdt:  - loopTask (CPU 1)
[23:43:15]E (18457) task_wdt: Tasks currently running:
[23:43:15]E (18457) task_wdt: CPU 0: IDLE
[23:43:15]E (18457) task_wdt: CPU 1: IDLE
[23:43:15]E (18457) task_wdt: Aborting.
[23:43:15]
[23:43:15]abort() was called at PC 0x400f88cc on core 0
[23:43:15]
[23:43:15]
[23:43:15]Backtrace:0x400837b9:0x3ffbe9bc |<-CORRUPTED
WARNING Found stack trace! Trying to decode it
WARNING Decoded 0x400837b9: panic_abort at /Users/ficeto/Desktop/ESP32/ESP32S2/esp-idf-public/components/esp_system/panic.c:402
[23:43:15]
[23:43:15]
[23:43:15]
[23:43:15]
[23:43:15]ELF file SHA256: 0000000000000000
[23:43:15]
[23:43:15]Rebooting...
[23:43:15]ets Jun  8 2016 00:22:57
[23:43:15]
[23:43:15]rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
[23:43:15]configsip: 188777542, SPIWP:0xee
[23:43:15]clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
[23:43:15]mode:DIO, clock div:2
[23:43:15]load:0x3fff0030,len:1184
[23:43:15]load:0x40078000,len:13132
[23:43:15]load:0x40080400,len:3036
[23:43:15]entry 0x400805e4
[23:43:16][I][logger:258]: Log initialized
[23:43:16][C][ota:469]: There have been 8 suspected unsuccessful boot attempts.
(but also does not work with logging removed)
Here is my config in case anyone wants to compare notes
# based on https://github.com/ayufan/esphome-components
external_components:
  - source: github://ayufan/esphome-components

esphome:
  name: eq3-relay

esp32:
  board: ttgo-lora32-v1
  framework:
    type: arduino

# Home Assistant API
api:
  encryption:
    key: !secret encryption_key

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password

time:
  - platform: homeassistant
    id: esptime

climate:
  - platform: eq3_v2
    name: Test-EQ3-1
    # mac address slightly changed
    mac_address: "00:1A:22:01:01:01"
    update_interval: 30min

not sure any of this helps, sadly.

ccoenen avatar Feb 25 '23 22:02 ccoenen