Skip to content

Commit 690c06b

Browse files
authored
Update install-esp-idf.sh
1 parent 55a9d4c commit 690c06b

File tree

1 file changed

+17
-5
lines changed

1 file changed

+17
-5
lines changed

tools/install-esp-idf.sh

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ if [ ! -d "$IDF_PATH" ]; then
3737
idf_was_installed="1"
3838
else
3939
# update existing branch
40-
echo "ESP-IDF is already installed, updating branch '$IDF_BRANCH'"
40+
echo "ESP-IDF is already installed, updating branch $IDF_BRANCH"
4141
cd $IDF_PATH
4242
git pull
4343
git reset --hard $IDF_BRANCH
@@ -61,18 +61,30 @@ fi
6161
#
6262

6363
if [ ! -x $idf_was_installed ] || [ ! -x $commit_predefined ]; then
64-
git submodule update --recursive
64+
git submodule update --recursive
6565
$IDF_PATH/install.sh
6666

67-
# Temporarily patch the ESP32-S2 I2C LL driver to keep the clock source
67+
# 1) Temporarily patch the ESP32-S2 I2C LL driver to keep the clock source
68+
# 2) Temporarily fix for mmu map and late init of psram https://github.com/espressif/arduino-esp32/issues/9936
6869
cd $IDF_PATH
69-
patch -p1 -N -i "$AR_ROOT/patches/esp32s2_i2c_ll_master_init.diff"
70+
patch -p1 -N -i ../patches/esp32s2_i2c_ll_master_init.diff
71+
patch -p1 -N -i ../patches/mmu_map.diff
72+
patch -p1 -N -i ../patches/lwip_max_tcp_pcb.diff
7073
cd -
7174

72-
# Patch to use the framework included "framework-arduinoespressif32-libs"
75+
# Patch to use the framework included "framework-arduinoespressif32-libs"
76+
# Get the exact IDF version from file "version.txt"
7377
cd "$AR_COMPS/arduino"
78+
cd $IDF_PATH
7479
patch -p1 -N -i "$AR_ROOT/patches/platformio-build.diff"
80+
export IDF_VERSION=$(<version.txt)
7581
cd -
82+
83+
# Get the exact IDF version from file "version.txt"
84+
cd $IDF_PATH
85+
export IDF_VERSION=$(<version.txt)
86+
echo "IDF version: $IDF_VERSION"
87+
cd -
7688
fi
7789

7890
#

0 commit comments

Comments
 (0)