diff options
-rw-r--r-- | src/tb/tb_keywrap_mkmif.v | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/tb/tb_keywrap_mkmif.v b/src/tb/tb_keywrap_mkmif.v index 06e3356..55305ff 100644 --- a/src/tb/tb_keywrap_mkmif.v +++ b/src/tb/tb_keywrap_mkmif.v @@ -168,6 +168,26 @@ module tb_keywrap_mkmif(); //---------------------------------------------------------------- + // dump_mem + // + // Dump the contents of the memory model. + //---------------------------------------------------------------- + task dump_mem; + begin : dump_mem + integer i; + + $display("Contents of the first 256 bytes in the serial memory:"); + for (i = 0 ; i < 256 ; i = i + 8) + $display("0x%01x 0x%01x 0x%01x 0x%01x 0x%01x 0x%01x 0x%01x 0x%01x", + mem.MemoryBlock[i], mem.MemoryBlock[i + 1], + mem.MemoryBlock[i + 2], mem.MemoryBlock[i + 3], + mem.MemoryBlock[i + 4], mem.MemoryBlock[i + 5], + mem.MemoryBlock[i + 6], mem.MemoryBlock[i + 7]); + end + endtask // dump_mem + + + //---------------------------------------------------------------- // init_sim() // // Initialize all counters and testbed functionality as well @@ -301,8 +321,10 @@ module tb_keywrap_mkmif(); init_sim(); reset_dut(); + dump_mem(); test_init_mem(); test_write_status(); + dump_mem(); $display(""); $display("*** Keywrap mkmif integration testbench done. ***"); |