# https://github.com/open-tool-forge/fpga-toolchain/releases
read os <<< "linux"
read arch < <( uname -i )
read url < <(
curl "https://api.github.com/repos/open-tool-forge/fpga-toolchain/releases/latest" \
| jq -r \
--arg os "${os}" \
--arg arch "${arch}" \
'.assets[] | select(.name | contains($os + "_" + $arch)) | select(.name | endswith(".tar.gz")) | .browser_download_url'
)
curl -LO "${url}"
tar -xvf "${url##*/}"
export PATH="$(readlink -f fpga-toolchain/bin/):${PATH}"
yosys -V
nextpnr-ecp5 -V
ATTRS{idVendor}=="1209", ATTRS{idProduct}=="5af0", MODE="0666", GROUP="plugdev", TAG+="uaccess"
udevadm control --reload-rules
git clone https://github.com/gregdavill/OrangeCrab-examples
cd OrangeCrab-examples/verilog/blink
make
Press button, and plug in... LED should fade RGB.
make dfu
LED should fade in/out Orange, and then switch to the new bitstream.
NOTE: the yosys
toolchain must still be on your ${PATH}
.
cd OrangeCrab-examples/nmigen
python3 -m venv venv
. venv/bin/activate
pip install --upgrade git+https://github.com/nmigen/nmigen-boards#egg=nmigen-boards
# enter bootloader
python blink.py
"getting started with OrangeCrap"... freudian slip maybe? ;)