Correct. Because for framework = arduino
, you have a precompiled version of ESP-IDF, which you can’t just change the ESP-IDF config flag afterwards. You have to configure it to compile ESP-IDF from source and the Arduino framework as a component on top. In that ESP-IDF project, you then have a sdkconfig to configure.
For ESP-IDF 4.4.7 + Arduino-ESP32 2.0.17. use platform = espressif32@6.11.0
and the example from https://github.com/platformio/platform-espressif32/tree/develop/examples/espidf-arduino-blink
For ESP-IDF 5.4.1 + Arduino-ESP32 3.2.0 use platform = https://github.com/pioarduino/platform-espressif32/releases/download/54.03.20/platform-espressif32.zip
and the example from https://github.com/pioarduino/platform-espressif32/tree/54.03.20/examples/espidf-arduino-blink.