Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
H
HDL
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RTSD
HDL
Commits
55066b3e
Commit
55066b3e
authored
6 years ago
by
Eric Kooistra
Browse files
Options
Downloads
Patches
Plain Diff
Improved user interface.
parent
e63fd944
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
applications/apertif/commissioning/apertif_synthesize_all.sh
+144
-32
144 additions, 32 deletions
applications/apertif/commissioning/apertif_synthesize_all.sh
with
144 additions
and
32 deletions
applications/apertif/commissioning/apertif_synthesize_all.sh
+
144
−
32
View file @
55066b3e
###############################################################################
###############################################################################
#
#
# Copyright (C) 201
8
# Copyright (C) 201
9
# ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
# ASTRON (Netherlands Institute for Radio Astronomy) <http://www.astron.nl/>
# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands
#
#
...
@@ -20,39 +20,151 @@
...
@@ -20,39 +20,151 @@
###############################################################################
###############################################################################
# Author : Eric Kooistra
# Author : Eric Kooistra
# Purpose: Recreate FPGA images for Apertif
# Usage : . $RADIOHDL/applications/apertif/commissioning/apertif_synthesize_all.sh
# Usage : . $RADIOHDL/applications/apertif/commissioning/apertif_synthesize_all.sh
# - first use DEMO_RUN = 1 to check the user settings
# - then use DEMO_RUN = 0 to execute the user settings
################################################################################
# User interface
DEMO_RUN
=
0
# 0 is execute script, else demo run with only echo statements
DEMO_RUN
=
1
CLEAN
=
0
# 1 is clean design build dir, else reuse existing design build dir
CLEAN
=
1
MMM
=
0
# 1 is do SOPC or QSYS, else skip it
MMM
=
1
SYNTHESIS
=
0
# 1 is do synthesis, else skip it
SYNTHESIS
=
1
DESIGNS
=
'apertif_unb1_bn_filterbank
apertif_unb1_fn_beamformer_trans
apertif_unb1_fn_beamformer_trans_bm6
apertif_unb1_correlator_full
apertif_unb1_correlator_full_bm6'
DESIGNS
=
'apertif_unb1_correlator_full
apertif_unb1_correlator_full_bm6
apertif_unb1_bn_filterbank
apertif_unb1_fn_beamformer_trans
apertif_unb1_fn_beamformer_trans_bm6'
#DESIGNS='apertif_unb1_bn_filterbank'
#DESIGNS='apertif_unb1_fn_beamformer_trans'
#DESIGNS='apertif_unb1_fn_beamformer_trans_bm6'
#DESIGNS='apertif_unb1_correlator_full'
#DESIGNS='apertif_unb1_correlator_full_bm6'
################################################################################
# Create log file
LOG_FILE
=
apertif_synthesize_all.log
date
>
$LOG_FILE
###############################################################################
echo
">>> User inputs"
>>
$LOG_FILE
echo
". Demo run =
$DEMO_RUN
"
>>
$LOG_FILE
echo
". Clean design build dir =
$CLEAN
"
>>
$LOG_FILE
echo
". Create SOPC or QSYS =
$MMM
"
>>
$LOG_FILE
echo
". Do synthesis =
$SYNTHESIS
"
>>
$LOG_FILE
echo
". FPGA designs ="
>>
$LOG_FILE
for
design
in
$DESIGNS
;
do
echo
"
$design
"
>>
$LOG_FILE
done
echo
""
>>
$LOG_FILE
echo
"Start"
# Preparations
# Preparations
cd
$RADIOHDL
cd
$RADIOHDL
echo
">>> SVN update to get revision"
>>
$LOG_FILE
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
svn up
# do svn up on trunk to get latest SVN revision number in image system_info
svn up
# do svn up on trunk to get latest SVN revision number in image system_info
fi
echo
""
>>
$LOG_FILE
###############################################################################
if
[
"
$CLEAN
"
==
"1"
]
;
then
for
design
in
$DESIGNS
;
do
echo
">>> Remove build dir:
$design
"
>>
$LOG_FILE
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
echo
# avoid empty fi,fi in case rm is commented
rm
-rf
$RADIOHDL
/build/unb1/quartus/
$design
fi
done
fi
echo
""
>>
$LOG_FILE
###############################################################################
echo
">>> Update build dir"
>>
$LOG_FILE
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
python
$RADIOHDL
/tools/oneclick/base/quartus_config.py
-t
unb1
python
$RADIOHDL
/tools/oneclick/base/quartus_config.py
-t
unb1
fi
echo
""
>>
$LOG_FILE
## Create Sopc
###############################################################################
#run_sopc unb1 apertif_unb1_bn_filterbank
if
[
"
$MMM
"
==
"1"
]
;
then
#run_sopc unb1 apertif_unb1_fn_beamformer_trans
for
design
in
$DESIGNS
;
do
#run_sopc unb1 apertif_unb1_fn_beamformer_trans_bm6
if
[
"
$design
"
==
"apertif_unb1_bn_filterbank"
]
;
then
#
echo
">>> Create SOPC:
$design
"
>>
$LOG_FILE
## Create Qsys
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
#run_qsys unb1 apertif_unb1_correlator_full
run_sopc unb1
$design
#run_qsys unb1 apertif_unb1_correlator_full_bm6
fi
#
fi
#cd $RADIOHDL/applications/apertif/designs/apertif_unb1_correlator/revisions/apertif_unb1_correlator_full
if
[
"
${
design
:0:32
}
"
==
"apertif_unb1_fn_beamformer_trans"
]
;
then
#./qsys_delete_duplicates_full.sh
echo
">>> Create SOPC:
$design
"
>>
$LOG_FILE
#cd $RADIOHDL
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
#
run_sopc unb1
$design
#cd $RADIOHDL/applications/apertif/designs/apertif_unb1_correlator/revisions/apertif_unb1_correlator_full_bm6
fi
#./qsys_delete_duplicates_full_bm6.sh
fi
#cd $RADIOHDL
if
[
"
${
design
:0:28
}
"
==
"apertif_unb1_correlator_full"
]
;
then
echo
">>> Create QSYS:
$design
"
>>
$LOG_FILE
# Do synthesis
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
#run_qcomp unb1 apertif_unb1_correlator_full --seed=1,2,3,4,5 --clk=unb1_board_clk200
run_qsys unb1
$design
#run_qcomp unb1 apertif_unb1_correlator_full_bm6 --seed=1,2,3,4,5 --clk=unb1_board_clk200
cd
$RADIOHDL
/applications/apertif/designs/
$design
/revisions/
$design
#run_qcomp unb1 apertif_unb1_bn_filterbank --seed=1 --clk=unb1_board_clk200 ;run_rbf unb1 apertif_unb1_bn_filterbank
./qsys_delete_duplicates_full.sh
run_qcomp unb1 apertif_unb1_fn_beamformer_trans
--seed
=
1
--clk
=
pll_afi_clk
;
run_rbf unb1 apertif_unb1_fn_beamformer_trans
cd
$RADIOHDL
#run_qcomp unb1 apertif_unb1_fn_beamformer_trans_bm6 --seed=1 --clk=pll_afi_clk ;run_rbf unb1 apertif_unb1_fn_beamformer_trans_bm6
fi
fi
# Create rbf
done
#run_rbf unb1 apertif_unb1_correlator_full
echo
""
>>
$LOG_FILE
#run_rbf unb1 apertif_unb1_correlator_full_bm6
fi
echo
"Done"
###############################################################################
if
[
"
$SYNTHESIS
"
==
"1"
]
;
then
for
design
in
$DESIGNS
;
do
if
[
"
$design
"
==
"apertif_unb1_bn_filterbank"
]
;
then
echo
">>> Do synthesis and create rbf:
$design
"
>>
$LOG_FILE
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
run_qcomp unb1
$design
--seed
=
1
--clk
=
unb1_board_clk200
run_rbf unb1
$design
fi
fi
if
[
"
${
design
:0:32
}
"
==
"apertif_unb1_fn_beamformer_trans"
]
;
then
echo
">>> Do synthesis and create rbf:
$design
"
>>
$LOG_FILE
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
run_qcomp unb1
$design
--seed
=
1
--clk
=
pll_afi_clk
run_rbf unb1
$design
fi
fi
if
[
"
${
design
:0:28
}
"
==
"apertif_unb1_correlator_full"
]
;
then
echo
">>> Do synthesis:
$design
"
>>
$LOG_FILE
if
[
"
$DEMO_RUN
"
==
"0"
]
;
then
run_qcomp unb1
$design
--seed
=
1,2,3,4,5
--clk
=
unb1_board_clk200
# No automatic run_rbf, do this manualy for seed with best clock speed. Procedure:
# . rm -rf $design active directory
# . rm -rf the other $design*MHz_r* that achieve < 200 MHz
# . cp -rp the $design*MHz_r* directory with the highest clock speed to the $design active directory
# . run_rbf unb1 $design
# . cp -p $design-r*.rbf $design*MHz_r* directory with the highest clock speed
# . optionally rm -rf the other $design*MHz_r* that are > 200MHz but less than the maximum achieved
fi
fi
done
echo
""
>>
$LOG_FILE
fi
###############################################################################
echo
"Done"
>>
$LOG_FILE
cat
$LOG_FILE
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment