Pico based I2S Synthesizer
git clone --recursive https://github.com/HackerSchool/pico-synth.git
cd pico-synth
If you already cloned without --recursive
, initialize submodules manually:
git submodule update --init --recursive
sudo apt install cmake gcc-arm-none-eabi libnewlib-arm-none-eabi build-essential
mkdir -p ~/pico && cd ~/pico
git clone --recursive https://github.com/raspberrypi/pico-sdk.git
cd pico-sdk
git submodule update --init
cd ~/pico
git clone --recursive https://github.com/raspberrypi/pico-extras.git
Before building, set the paths so CMake can find the SDK and extras:
export PICO_SDK_PATH=~/pico/pico-sdk
export PICO_EXTRAS_PATH=~/pico/pico-extras
To make this permanent, add these lines to ~/.bashrc
or ~/.zshrc
:
echo 'export PICO_SDK_PATH=~/pico/pico-sdk' >> ~/.bashrc
echo 'export PICO_EXTRAS_PATH=~/pico/pico-extras' >> ~/.bashrc
source ~/.bashrc
- Create a Build Directory
mkdir -p build && cd build
- Run CMake to Configure the Build
cmake ..
- Compile the Code
make -j$(nproc)
- Hold down the BOOTSEL button on the Pico.
- Plug it into your computer via USB.
- It should appear as a USB mass storage device (RPI-RP2).
Once built, the pico-synth
binary (.uf2
file) will be in build/
:
cp build/pico-synth.uf2 /media/$USER/RPI-RP2/
The Pico will automatically reboot and start running the synthesizer!
-
"pico_sdk_import.cmake not found" error?
- Make sure
PICO_SDK_PATH
is set correctly. - Try running
source ~/.bashrc
.
- Make sure
-
No
*.uf2
file aftermake
?- Check the build log for errors.
- Ensure
pico_enable_stdio_usb(${bin_name} 1)
is set inCMakeLists.txt
.