esphome / issues

Issue Tracker for ESPHome
https://esphome.io/
290 stars 36 forks source link

2024.10.0 not setting ignore_efuse_mac_crc #6333

Open latargere opened 1 week ago

latargere commented 1 week ago

The problem

After updating to 2024.10.0, my devices with ignore_efuse_mac_crc don’t boot anymore. Error is: Base MAC address from BLK3 of EFUSE version error

Rolling back to 2024.9.2 and everything works again.

Which version of ESPHome has the issue?

2024.10.0

What type of installation are you using?

Home Assistant Add-on

Which version of Home Assistant has the issue?

2024.10.2

What platform are you using?

ESP32

Board

No response

Component causing the issue

Boot

Example YAML snippet

esp32:
  board: esp32doit-devkit-v1
  framework:
    type: esp-idf
    sdkconfig_options:
      CONFIG_FREERTOS_UNICORE: y
    advanced:
      ignore_efuse_mac_crc: true

Anything in the logs that might be useful for us?

Base MAC address from BLK3 of EFUSE version error

Additional information

No response

gzxto1 commented 1 week ago

Same Problem here with my ULANZI Display, but not having configured the option ignore_efuse_mac_crc: true

Rollback fixed it again


esp32:
  board: esp32dev

[14:50:24][W][esp-idf:000]: E (155944) system_api: Base MAC address from BLK3 of EFUSE version error, version = 0

snipes040 commented 1 week ago

I have this issue as well, has broken both my Yeelight 1s led lightstrips that I flashed ESPhome with :) I also have the ignore_efuse_mac_crc: true config entry.

phbaer commented 1 week ago

Same here, some esp32-based ceiling light. Rolled back to 2024.9.x:

esp32:
  board: esp32doit-devkit-v1

  framework:
    type: esp-idf
    sdkconfig_options:
      CONFIG_FREERTOS_UNICORE: y
    advanced:
      ignore_efuse_mac_crc: true
randybb commented 1 week ago

There is a new ignore ignore_efuse_custom_mac: introduced in this release as EFUSE can be used for storing any data, but can be used for MAC address as well. I agree, if you specifically say that there is a MAC with a wrong CRC in EFUSE, then it means there is a stored MAC too. - EDIT: it makes sense, because the stored MAC is not a correct MAC due CRC mismatch, so you need to explicitly tell that you want to use such wrong MAC.

This is what I have for my xiaomi bs2 lamps:

esp32:
  board: esp32doit-devkit-v1
  framework:
    type: esp-idf
    sdkconfig_options:
      CONFIG_FREERTOS_UNICORE: y
    advanced:
      ignore_efuse_custom_mac: true
      ignore_efuse_mac_crc: true
phbaer commented 1 week ago

Will try that tomorrow. Thanks, @randybb!

lubeda commented 1 week ago

also problems here, also with an ulanzi https://github.com/lubeda/EspHoMaTriXv2/issues/248

snipes040 commented 1 week ago

There is a new ignore ignore_efuse_custom_mac: introduced in this release as EFUSE can be used for storing any data, but can be used for MAC address as well. I agree, if you specifically say that there is a MAC with a wrong CRC in EFUSE, then it means there is a stored MAC too.

This is what I have for my xiaomi bs2 lamps:

esp32:
  board: esp32doit-devkit-v1
  framework:
    type: esp-idf
    sdkconfig_options:
      CONFIG_FREERTOS_UNICORE: y
    advanced:
      ignore_efuse_custom_mac: true
      ignore_efuse_mac_crc: true

I tried this config and I'm getting the same errors:

[15:18:21][D][esp-idf:000]: E (1027709) system_api: Base MAC address from BLK0 of EFUSE CRC error, efuse_crc = 0x00; calc_crc = 0xda

[15:18:21][D][esp-idf:000]: W (1027712) system_api: Ignore MAC CRC error
randybb commented 1 week ago

Error is fine as the CRC is wrong (but yes, if you are explicitly ignoring it, why it is showing it? :) ) and the warning too. The issue was in wrong MAC - esphome used some default one, now it is using the one which is in EFUSE.

clfberlin commented 1 week ago

ESPHome can no longer properly discover or tell apart my three Ulanzis. See also: @lubeda - https://github.com/lubeda/EspHoMaTriXv2/issues/248

TheAceBlock commented 6 days ago

I had a similar issue: after the upgrade, the device cannot be discovered by Home Assistant properly anymore (shows up as a new device). Setting ignore_efuse_custom_mac: true initially doesn't seem to help with this issue, however after cleaning the build files, everything seems to work again. There will still be the following error with a warnong shown in the log, but it shouldn't affect any functionalities.

[TIME REDACTED][D][esp-idf:000]: E (767048) system_api: Base MAC address from BLK0 of EFUSE CRC error, efuse_crc = 0x5c; calc_crc = 0xed

[TIME REDACTED][D][esp-idf:000]: W (767051) system_api: Ignore MAC CRC error

Here's some findings from my testing:

Partial bootloop log ``` W (1182) phy_init: failed to load RF calibESP_ERROR_CHECK failed: esp_err_t 0x109 (ESP_ERR_INVALID_CRC) at 0x40088b10 file: "IDF/components/esp_phy/src/phy_init.c" line 739 func: esp_phy_load_cal_and_init expression: esp_efuse_mac_get_default(sta_mac) abort() was called at PC 0x40088b13 on core 0 Backtrace: 0x400821a6:0x3ffc2700 0x40088b1d:0x3ffc2720 0x4008e89e:0x3ffc2740 0x40088b13:0x3ffc27b0 0x400fb7dd:0x3ffc27d0 0x400fb89d:0x3ffc2800 0x400fd5cb:0x3ffc2820 0x4012db6a:0x3ffc2840 0x4012e309:0x3ffc2860 0x4012c964:0x3ffc2880 0x400902e1:0x3ffc28a0 ELF file SHA256: Rebooting.. ```
snipes040 commented 6 days ago

alright so I came back to say that everything is now working!

Here is my code and I needed to do a fresh re-install. Do not try without ignore_efuse_mac_crc, I now have to reflash manually lol


esp32:
  board: esp32doit-devkit-v1
  framework:
    type: esp-idf
    sdkconfig_options:
      CONFIG_FREERTOS_UNICORE: y
    advanced:
      ignore_efuse_custom_mac: true
      ignore_efuse_mac_crc: true
phbaer commented 6 days ago

@randybb, @TheAceBlock, @snipes040: yes, same here. Setting both works. Thanks a lot!

lafriks commented 6 days ago

Problem is that these options can not be set for framework type arduino 🤔

kbx81 commented 4 days ago

Problem is that these options can not be set for framework type arduino 🤔

@lafriks fixed in https://github.com/esphome/esphome/pull/7644