From f01a050db244b01c5e8d1d6a3a8099c88ff9edf5 Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Sat, 7 Mar 2026 17:21:00 -1000 Subject: [PATCH] [i2s_audio] Include legacy driver IDF component when use_legacy is set The "driver" shim component (providing driver/i2s.h) was excluded by default in #13623 to reduce compile time. When use_legacy is true, the i2s_audio component needs this shim for the legacy I2S API headers. --- esphome/components/i2s_audio/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/esphome/components/i2s_audio/__init__.py b/esphome/components/i2s_audio/__init__.py index 1cd2e97a5e..65b09b93f6 100644 --- a/esphome/components/i2s_audio/__init__.py +++ b/esphome/components/i2s_audio/__init__.py @@ -281,6 +281,8 @@ async def to_code(config): if use_legacy(): cg.add_define("USE_I2S_LEGACY") + # Legacy I2S API lives in the "driver" shim component (driver/i2s.h) + include_builtin_idf_component("driver") # Helps avoid callbacks being skipped due to processor load add_idf_sdkconfig_option("CONFIG_I2S_ISR_IRAM_SAFE", True)