2015-01-23 23:07:56 +08:00
|
|
|
#!/bin/bash
|
|
|
|
|
2015-04-04 22:27:43 +08:00
|
|
|
BUILD_SETTINGS_FILE=$HOME/.mlabs/build_settings.sh
|
|
|
|
|
|
|
|
if [ -f $BUILD_SETTINGS_FILE ]
|
|
|
|
then
|
|
|
|
source $BUILD_SETTINGS_FILE
|
|
|
|
fi
|
|
|
|
|
2015-02-07 01:37:35 +08:00
|
|
|
ARTIQ_GUI=1 $PYTHON setup.py install --single-version-externally-managed --record=record.txt
|
2015-03-04 00:23:34 +08:00
|
|
|
git clone --recursive https://github.com/m-labs/misoc
|
|
|
|
export MSCDIR=$SRC_DIR/misoc
|
2015-04-04 22:27:43 +08:00
|
|
|
|
2015-03-04 00:23:34 +08:00
|
|
|
ARTIQ_PREFIX=$PREFIX/lib/python3.4/site-packages/artiq
|
2015-04-10 20:00:46 +08:00
|
|
|
BIN_PREFIX=$ARTIQ_PREFIX/binaries/
|
2015-03-04 00:23:34 +08:00
|
|
|
mkdir -p $ARTIQ_PREFIX/misc
|
2015-04-04 22:27:43 +08:00
|
|
|
mkdir -p $BIN_PREFIX/kc705 $BIN_PREFIX/pipistrello
|
|
|
|
|
2015-07-31 14:52:15 +08:00
|
|
|
# build for KC705
|
2015-07-31 13:58:28 +08:00
|
|
|
|
2015-07-31 15:02:54 +08:00
|
|
|
cd $SRC_DIR/misoc; $PYTHON make.py -X ../soc -t artiq_kc705 build-headers build-bios; cd -
|
2015-04-04 22:27:43 +08:00
|
|
|
make -C soc/runtime clean runtime.fbi
|
2015-07-31 15:02:54 +08:00
|
|
|
cd $SRC_DIR/misoc; $PYTHON make.py -X ../soc -t artiq_kc705 $MISOC_EXTRA_VIVADO_CMDLINE build-bitstream; cd -
|
2015-04-04 22:27:43 +08:00
|
|
|
|
|
|
|
# install KC705 binaries
|
|
|
|
|
2015-06-17 00:14:26 +08:00
|
|
|
cp soc/runtime/runtime.fbi $BIN_PREFIX/kc705/
|
2015-04-04 22:27:43 +08:00
|
|
|
cp $SRC_DIR/misoc/software/bios/bios.bin $BIN_PREFIX/kc705/
|
2015-06-16 07:31:33 +08:00
|
|
|
cp $SRC_DIR/misoc/build/artiq_kc705-nist_qc1-kc705.bit $BIN_PREFIX/kc705/
|
2015-06-15 23:28:13 +08:00
|
|
|
wget http://sionneau.net/artiq/binaries/kc705/flash_proxy/bscan_spi_kc705.bit
|
|
|
|
mv bscan_spi_kc705.bit $BIN_PREFIX/kc705/
|
2015-04-04 22:27:43 +08:00
|
|
|
|
2015-06-17 00:12:38 +08:00
|
|
|
# build for Pipistrello
|
|
|
|
|
2015-07-31 15:02:54 +08:00
|
|
|
cd $SRC_DIR/misoc; $PYTHON make.py -X ../soc -t artiq_pipistrello build-headers build-bios; cd -
|
2015-06-17 00:12:38 +08:00
|
|
|
make -C soc/runtime clean runtime.fbi
|
2015-07-31 15:02:54 +08:00
|
|
|
cd $SRC_DIR/misoc; $PYTHON make.py -X ../soc -t artiq_pipistrello $MISOC_EXTRA_ISE_CMDLINE build-bitstream; cd -
|
2015-06-17 00:12:38 +08:00
|
|
|
|
2015-04-04 22:27:43 +08:00
|
|
|
# install Pipistrello binaries
|
|
|
|
|
|
|
|
cp soc/runtime/runtime.fbi $BIN_PREFIX/pipistrello/
|
|
|
|
cp $SRC_DIR/misoc/software/bios/bios.bin $BIN_PREFIX/pipistrello/
|
2015-06-16 07:31:33 +08:00
|
|
|
cp $SRC_DIR/misoc/build/artiq_pipistrello-nist_qc1-pipistrello.bit $BIN_PREFIX/pipistrello/
|
2015-06-15 23:28:13 +08:00
|
|
|
wget http://www.phys.ethz.ch/~robertjo/bscan_spi_lx45_csg324.bit
|
|
|
|
mv bscan_spi_lx45_csg324.bit $BIN_PREFIX/pipistrello/
|
2015-04-04 22:27:43 +08:00
|
|
|
|
2015-03-04 00:23:34 +08:00
|
|
|
cp artiq/frontend/artiq_flash.sh $PREFIX/bin
|
2015-07-04 18:49:42 +08:00
|
|
|
|
|
|
|
# misc
|
|
|
|
cp misc/99-papilio.rules $ARTIQ_PREFIX/misc/
|
|
|
|
cp misc/99-kc705.rules $ARTIQ_PREFIX/misc/
|