Sha256: 706a968d7407be5f058b90d988045c2f4531758d461d8a59affa3de2628f6447
Contents?: true
Size: 393 Bytes
Versions: 7
Compression:
Stored size: 393 Bytes
Contents
module register_file ( input wire [1:0] rdReg, input wire [1:0] wtReg, input wire rw, input wire enable, input wire [3:0] inBus, output reg [3:0] outBus ); reg [3:0] register [0:3]; always @(rdReg, wtReg, rw, enable) begin if (rw == 0) begin outBus = register[rdReg]; end else if (enable) begin register[wtReg] = inBus; end end endmodule
Version data entries
7 entries across 7 versions & 1 rubygems