-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompile
More file actions
executable file
·42 lines (31 loc) · 850 Bytes
/
compile
File metadata and controls
executable file
·42 lines (31 loc) · 850 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/bin/sh
# Require two args
if [ $# -ne 2 ]; then
echo ""
echo "usage: "$0" <waveform_file> <destination_file>"
echo ""
exit
fi
# Destination directory
DST_DIR=lod
if [ ! -d "$DST_DIR" ]; then
mkdir "$DST_DIR"
fi
echo ""
echo "Assembling DSP code ..."
echo ""
# DOWNLOAD selects application code to be loaded from EEPROM or
# downloaded from the host over the fiber optic link
DOWNLOAD=HOST
WAVEFORM_FILE=$1
DST_FILE="$DST_DIR"/$2
# Assemble and link
wine /opt/CLAS563/BIN/ASM56300 -b -l"$DST_FILE".ls -d DOWNLOAD $DOWNLOAD -d WAVEFORM_FILE "$WAVEFORM_FILE" tim.asm
wine /opt/CLAS563/BIN/DSPLNK -btim.cld -v tim.cln
rm -f "$DST_FILE".lod
wine /opt/CLAS563/BIN/CLDLOD tim.cld > "$DST_FILE".lod
rm tim.cln ; rm tim.cld
dos2unix "$DST_FILE".lod
echo ""
echo "Created file $DST_FILE.lod for downloading over optical fiber"
echo ""