top_level.v 961 Bytes
////////////////////////////////////////////////////////////////////////
//
// Project Reality
//
// module:      top_level
// description: Top Level Driver for vi_rand module
//
// designer:    Kevin Luster
// date:        11/7/94
//
////////////////////////////////////////////////////////////////////////

`timescale 10ps / 10ps  //1unit = 0.01ns

module top_level();

wire vclk;
wire reset_l;
wire [5:0] rand;

//instance driver
driver driver (.vclk(vclk), .reset_l(reset_l));

//instance rand
vi_rand vi_rand (.vclk(vclk), .reset_l(reset_l), .rand(rand));

//instance display
display display (.vclk(vclk), .reset_l(reset_l), .rand(rand));
	
//  kill simulation when tabular file read

always @(driver.EndVectors)
  begin
    if ($close_output_files() == -1)
      begin
	$write("Cannot close output files");
      end
    $finish;
  end


    // dump file

initial
  begin
    if ($test$plusargs("dump"))
      $dumpvars;
  end

endmodule // top_level