Skip to content

Instantly share code, notes, and snippets.

@cversek
Created February 8, 2017 23:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cversek/0a9669b65e6ae2d655da07fb15098c57 to your computer and use it in GitHub Desktop.
Save cversek/0a9669b65e6ae2d655da07fb15098c57 to your computer and use it in GitHub Desktop.
Notes on building open-eio/circuitpython firmware with pawpaw outside of Vagrant machine
#!/bin/bash -x
#FIRST TIME SETUP
#install esp-open-sdk, Espressif ESP-IDF, and micropython dependencies
echo "Installing esp-open-sdk, Espressif ESP-IDF, and micropython dependencies..."
sudo apt-get update
sudo apt-get install -y build-essential git make unrar-free unzip \
autoconf automake libtool libtool-bin gcc g++ gperf \
flex bison texinfo gawk ncurses-dev libexpat-dev \
python sed libreadline-dev libffi-dev pkg-config \
help2man python-dev python-serial wget linux-image-extra-$(uname -r)
/esp8266-circuitpython-pawpaw/xtensa-esp32-elf/bin
#install Espressif ESP32 toolchain
echo "Installing Espressif ESP32 toolchain..."
cd ~
mkdir esp8266-circuitpython-pawpaw
cd esp8266-circuitpython-pawpaw
wget https://dl.espressif.com/dl/xtensa-esp32-elf-linux64-1.22.0-61-gab8375a-5.2.0.tar.gz
tar xvfz xtensa-esp32-elf-linux64-1.22.0-61-gab8375a-5.2.0.tar.gz
echo "PATH=$HOME/esp8266-circuitpython-pawpaw/xtensa-esp32-elf/bin:\$PATH" >> ~/.profile
# logout the log back in, for path to be updated, OR
export PATH=$HOME/esp8266-circuitpython-pawpaw/xtensa-esp32-elf/bin:$PATH
#install esp-open-sdk, Espressif ESP-IDF, and open-eio/circuitpython
echo "Installing esp-open-sdk, Espressif ESP-IDF, and open-eio/circuitpython source..."
git clone --recursive https://github.com/pfalcon/esp-open-sdk.git
git clone --recursive https://github.com/espressif/esp-idf.git
git clone --recursive https://github.com/open-eio/circuitpython.git
#build the esp-open-sdk NOTE: this can take up to 30 min on a slow computer
echo "Building the esp-open-sdk NOTE: this can take up to 30 min on a slow computer..."
cd ~/esp8266-circuitpython-pawpaw/esp-open-sdk
make STANDALONE=y
echo "PATH=$(pwd)/xtensa-lx106-elf/bin:\$PATH" >> ~/.profile
# logout the log back in, for path to be updated, OR
export PATH=$(pwd)/xtensa-lx106-elf/bin:$PATH
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment