[Cryptech-Commits] [core/rng/trng] 01/02: Writing a new word into the fifo.

git at cryptech.is git at cryptech.is
Sat Jul 18 09:36:29 UTC 2015


This is an automated email from the git hooks/post-receive script.

joachim at secworks.se pushed a commit to branch fifo_debug
in repository core/rng/trng.

commit 1f1b1bc2781ad4f18176de8ff372db44cfc9cd44
Author: Joachim Strömbergson <joachim at secworks.se>
Date:   Sat Jul 18 10:31:03 2015 +0200

    Writing a new word into the fifo.
---
 src/tb/tb_csprng_fifo.v | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/src/tb/tb_csprng_fifo.v b/src/tb/tb_csprng_fifo.v
index a1bf73c..aedcbbe 100644
--- a/src/tb/tb_csprng_fifo.v
+++ b/src/tb/tb_csprng_fifo.v
@@ -360,8 +360,8 @@ module tb_csprng_fifo();
   // words all the time.
   //----------------------------------------------------------------
   task fifo_test();
-    reg [7 : 0]   i;
-    reg [7 : 0]   j;
+    reg [7 : 0] i;
+    reg [7 : 0] j;
 
     begin
       $display("*** Test of FIFO by loading known data and then reading out.");
@@ -392,11 +392,18 @@ module tb_csprng_fifo();
       dump_fifo();
 
       // Write another 512-bit word into the fifo.
-      i = 8'd4;
+      write_w512(8'h40);
 
 
+      // Read out all of the rest of the data.
+      for (j = 0 ; j < 200 ; j = j + 1)
+        begin
+          read_w32();
+        end
+
+      dump_fifo();
     end
-  endtask // init_sim
+  endtask // fifo_test
 
 
   //----------------------------------------------------------------



More information about the Commits mailing list