Hello possible future lifesavers.
I was wondering if there was a I can use a modified ESP-IDF with the Arduino framework in platformio. For context, I want to make changes to the Lightweight IP (LwIP) library, which is a part of the Espressif SDK, but I can’t make direct changes to it because I only have access to the header files in the ~/.platformio/packages/framework-arduinoespressif32 folder. Considering I use the Arduino framework for my project within platformio through VS Code, what’s the easiest way for me to make changes to the LwIP library?
Here’s what I tried so far.
- I cloned the esp-idf repository and checked out to the version I usually use (v4.4.3).
- I then made some changes to the LwIP sources files.
- In my platformio.ini file, under [env], I added the line “platform_packages = framework-espidf@file://insertPathToEspIdf”
- Selected my environment via VSCode and hit Build
Initially, nothing happened and everything compiled as normal. It was still using the default files as opposed to my custom esp-idf. I then found this post Platform_packages in platformio.ini not working as expected - #2 by maxgerhardt saying that as long as I use the arduino framework, I have to use “framework-arduinoespressif32@…” so I did and now all the Arduino files are not found, presumably because it overwrote the Arduino layer. Which brings us back to…
How does one modify files within esp-idf whilst making no chances at the Arduino and platformio layer?