Open cjc7373 opened 11 months ago
One of those messages (/data/cache/platformio/packages/framework-espidf/components/bt/include/esp32c6/include/esp_bt.h:258:58: error: narrowing conversion of 'efuse_hal_chip_revision()' from 'uint32_t' {aka 'long unsigned int'} to 'uint8_t' {aka 'unsigned char'} [-Werror=narrowing]
) seem to be an error in ESP-IDF for esp32c6. I'll create a PR for it.
It looks like all of them is due to bugs in ESP-IDF.
Thanks, I applied your patch locally and the compile error has gone.
However, the bluetooth is still not working. And when I set log level to debug, I see the following lines:
[14:36:18][C][esp32_ble:243]: ESP32 BLE: bluetooth stack is not enabled
[14:36:18][C][esp32_ble_tracker:617]: BLE Tracker:
[14:36:18][C][esp32_ble_tracker:618]: Scan Duration: 300 s
[14:36:18][C][esp32_ble_tracker:619]: Scan Interval: 320.0 ms
[14:36:18][C][esp32_ble_tracker:620]: Scan Window: 30.0 ms
[14:36:18][C][esp32_ble_tracker:621]: Scan Type: ACTIVE
[14:36:18][C][esp32_ble_tracker:622]: Continuous Scanning: True
Any clue why this happens?
Thank you for bringing this to our attention, and we appreciate your patience. We have verified the issue you reported and provided a temporary solution. For this problem, we recommend modifying the esp_bt.h file by casting the return value of efuse_hal_chip_revision() to uint8_t as follows, matching the version_num structure member.
.version_num = (uint8_t)efuse_hal_chip_revision(),
This is a temporary workaround, and we plan to address this issue in future releases.
@luomanruo can you be more specific what you mean by modifying the esp_bt.h file? Also maybe any update on a potential permanent fix for this?
Issue still persists with ESP-IDF 5.2.2, PlatformIO 6.7.0 and ESPHome 2024.6.4:
Compiling .pioenvs/sens-1st-bedroom-ac/bootloader_support/src/esp_image_format.c.o In file included from src/esphome.h:26, from src/main.cpp:3: src/esphome/components/esp32_ble/const_esp32c6.h:62:1: warning: missing initializer for member ‘esp_bt_controller_config_t::cca_drop_mode’ [-Wmissing-field-initializers] 62 | }; | ^ src/esphome/components/esp32_ble/const_esp32c6.h:62:1: warning: missing initializer for member ‘esp_bt_controller_config_t::cca_low_tx_pwr’ [-Wmissing-field-initializers] src/esphome/components/esp32_ble/const_esp32c6.h:62:1: warning: missing initializer for member ‘esp_bt_controller_config_t::csa2_select’ [-Wmissing-field-initializers]
Issue still persists with ESP-IDF 5.3.0, PlatformIO 6.8.1 and ESPHome 2024.7.2:
In file included from src/esphome/components/esp32_ble/ble.cpp:6: src/esphome/components/esp32_ble/const_esp32c6.h:62:1: warning: missing initializer for member 'esp_bt_controller_config_t::cca_drop_mode' [-Wmissing-field-initializers] 62 | }; | ^ src/esphome/components/esp32_ble/const_esp32c6.h:62:1: warning: missing initializer for member 'esp_bt_controller_config_t::cca_low_tx_pwr' [-Wmissing-field-initializers] src/esphome/components/esp32_ble/const_esp32c6.h:62:1: warning: missing initializer for member 'esp_bt_controller_config_t::csa2_select' [-Wmissing-field-initializers]
The problem
When I tried to enable
esp32_ble_tracker
in my esp32-c6-devkitc-1 board, I encountered some compile error, see the logs below.Which version of ESPHome has the issue?
2023.9.0b2
What type of installation are you using?
Home Assistant Add-on
Which version of Home Assistant has the issue?
No response
What platform are you using?
ESP32-IDF
Board
No response
Component causing the issue
No response
Example YAML snippet
Anything in the logs that might be useful for us?
Additional information
No response