Skip to content

Commit 5519e9b

Browse files
authored
merged with master (#131)
Usercode improvment Signed-off-by: Alexandre CASTELLANE <alexandre.castellane@fr.ibm.com>
1 parent 6e93163 commit 5519e9b

4 files changed

Lines changed: 18 additions & 3 deletions

File tree

hardware/setup/patch_version.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,7 @@ sed -i "s/$SRC/$DST/" $1/$2
4040
SRC="define USERCODE 64'h.*"
4141
# usercode should be less than 64 bit long
4242
#usercode=`echo 0123456789ABCDEF`
43-
usercode=`echo 0000000000000000`
44-
DST="define USERCODE 64'h${usercode}"
43+
DST="define USERCODE 64'h${USERCODE}"
4544
sed -i "s/$SRC/$DST/" $1/$2
4645

4746

hardware/setup/snap_build.tcl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ if { $ila_debug == "TRUE" } {
100100
if { ($::env(REMOVE_TMP_FILES) == "TRUE") && ($impl_step == "ALL") } {
101101
puts [format "%-*s%-*s%-*s%-*s" $widthCol1 "" $widthCol2 "removing temp files" $widthCol3 "" $widthCol4 "[clock format [clock seconds] -format {%T %a %b %d %Y}]"]
102102
#We intentionally keep the latest dcp generated => opt_routed_design.dcp
103-
exec rm -rf $dcp_dir/synth_design.dcp
103+
if { $ila_debug != "TRUE" } {exec rm -rf $dcp_dir/synth_design.dcp}
104104
exec rm -rf $dcp_dir/opt_design.dcp
105105
exec rm -rf $dcp_dir/place_design.dcp
106106
exec rm -rf $dcp_dir/phys_opt_design.dcp

scripts/Kconfig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -890,3 +890,14 @@ config FLASH_USED
890890
default "TRUE" if ENABLE_FLASH
891891
default "FALSE" if ! ENABLE_FLASH
892892

893+
config ENABLE_USERCODE
894+
bool "Enable USER CODE (code will be requested to user later on)"
895+
default n
896+
help
897+
This allows user to define a user code associated to the FPGA content
898+
For ex user want to create 2 configuration with 2 different VIVADO versions
899+
900+
config USERCODE
901+
string "USERCODE(max64bits)"
902+
depends on ENABLE_USERCODE
903+
default "0000000000000000"

snap_env

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -307,6 +307,11 @@ while [ -z "$SETUP_DONE" ]; do
307307
SETUP_INFO="$SETUP_INFO\n To simulate a design with EMAC, it is recommended to use xcelium simulator (license needed) or use the Ethernet Loop-back option."
308308
fi
309309

310+
# Note: USERCODE requested
311+
if [ "$ENABLE_USERCODE" == "y" ]; then
312+
echo "USERCODE has been set to : $USERCODE";
313+
fi
314+
310315

311316
####### Print warning messages and create $snap_env_sh
312317
echo -e "======================================================="

0 commit comments

Comments
 (0)