-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathData_RAM.v
More file actions
40 lines (31 loc) · 883 Bytes
/
Copy pathData_RAM.v
File metadata and controls
40 lines (31 loc) · 883 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
`timescale 1ns / 1ps
//////////////////////////////////////////////////////////////////////////////////
// Company:
// Engineer:
//
// Create Date: 10.02.2025 16:20:14
// Design Name:
// Module Name: Data_RAM
// Project Name:
// Target Devices:
// Tool Versions:
// Description:
//
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Additional Comments:
//
//////////////////////////////////////////////////////////////////////////////////
module Data_RAM(
input read_enable, write_enable,
input [9:0] read_address, write_address,
input [31:0] data_in,
output reg [31:0] data_out
);
reg [31:0] memory [0:1023];
initial memory [0] = 32'h22222222;
always @ (posedge read_enable) data_out = memory[read_address];
always @ (posedge write_enable) memory[write_address] = data_in;
endmodule