国内Linux下配置esp-idf开发环境
本文最后更新于 1114 天前,其中的信息可能已经有所发展或是发生改变。

依赖安装

sudo apt update -y
sudo apt-get install git wget make libncurses-dev flex bison gperf python python-is-python2 python3-pip cmake -y
觉得慢的可以把源换成中科大或者阿里云的

设置pip源为阿里云

mkdir ~/.pip
cat > ~/.pip/pip.conf << EOF
[global]
index-url = http://mirrors.aliyun.com/pypi/simple/
[install]
trusted-host=mirrors.aliyun.com
disable-pip-version-check = true
timeout = 60
EOF

使用Github国内镜像

# 使用镜像
git config --global url."https://hub.fastgit.org/".insteadof https://github.com/
# 取消镜像
git config --global --unset url.https://hub.fastgit.org/.insteadof

获取esp-idf

mkdir ~/esp
cd ~/esp
git clone --recursive https://github.com/espressif/esp-idf.git
cd ~/esp/esp-idf
# 设置python3为默认
sudo update-alternatives --install /usr/bin/python python /usr/bin/python2 100
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 150
# 国内使用使用乐鑫的下载服务器
export IDF_GITHUB_ASSETS=dl.espressif.com/github_assets
./install.sh
~/.espressif/python_env/idf4.4_py3.8_env/bin/python -m pip install --upgrade pip

设置环境变量

# 临时环境变量
. ~/esp/esp-idf/export.sh
# 持久化环境变量
echo ". ~/esp/esp-idf/export.sh" >> /etc/profile.d/esp-idf.sh
暂无评论

发送评论 编辑评论


				
|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗㆆ)
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
颜文字
Emoji
小恐龙
花!
上一篇
下一篇