aboutsummaryrefslogtreecommitdiff
path: root/src/tb/tb_sha1_core.v
diff options
context:
space:
mode:
Diffstat (limited to 'src/tb/tb_sha1_core.v')
-rw-r--r--src/tb/tb_sha1_core.v16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/tb/tb_sha1_core.v b/src/tb/tb_sha1_core.v
index 8a5d11b..0ae592d 100644
--- a/src/tb/tb_sha1_core.v
+++ b/src/tb/tb_sha1_core.v
@@ -6,7 +6,8 @@
//
//
// Author: Joachim Strombergson
-// Copyright (c) 2014 SUNET
+// Copyright (c) 2014, SUNET
+// All rights reserved.
//
// Redistribution and use in source and binary forms, with or
// without modification, are permitted provided that the following
@@ -47,7 +48,8 @@ module tb_sha1_core();
//----------------------------------------------------------------
parameter DEBUG = 0;
- parameter CLK_HALF_PERIOD = 2;
+ parameter CLK_HALF_PERIOD = 1;
+ parameter CLK_PERIOD = CLK_HALF_PERIOD * 2;
//----------------------------------------------------------------
@@ -103,7 +105,7 @@ module tb_sha1_core();
//----------------------------------------------------------------
always
begin : sys_monitor
- #(2 * CLK_HALF_PERIOD);
+ #(CLK_PERIOD);
if (DEBUG)
begin
dump_dut_state();
@@ -225,7 +227,7 @@ module tb_sha1_core();
begin
while (!tb_ready)
begin
- #(2 * CLK_HALF_PERIOD);
+ #(CLK_PERIOD);
end
end
@@ -246,7 +248,7 @@ module tb_sha1_core();
tb_block = block;
tb_init = 1;
- #(2 * CLK_HALF_PERIOD);
+ #(CLK_PERIOD);
tb_init = 0;
wait_ready();
@@ -290,7 +292,7 @@ module tb_sha1_core();
$display("*** TC %0d first block started.", tc_number);
tb_block = block1;
tb_init = 1;
- #(2 * CLK_HALF_PERIOD);
+ #(CLK_PERIOD);
tb_init = 0;
wait_ready();
db_digest1 = tb_digest;
@@ -299,7 +301,7 @@ module tb_sha1_core();
$display("*** TC %0d second block started.", tc_number);
tb_block = block2;
tb_next = 1;
- #(2 * CLK_HALF_PERIOD);
+ #(CLK_PERIOD);
tb_next = 0;
wait_ready();
$display("*** TC %0d second block done.", tc_number);