multidimensional RAM
hello everyone,
I am using altera DE2, cyclonII and quartusII 9.1 . I want to make multidimensional RAM. I am working on video frame, so I need to store pixels in the 2D-ram.
my code is like this :
module memory (iCLK, we, a, b, idata, odata);
input iCLK;
//input iRST;
input we;
input [639:0] a;
input [1279:0]b;
input [9:0] idata;
output [9:0] odata;
reg [9:0] memory [9:0][9:0];
integer j,k;
always@(posedge iCLK)
begin
if (we)
begin
for(k = 0; k < 10; k = k +1)
for(j = 0; j < 10; j = j + 1)
memory[k][j] <= idata;
end
end
assign odata = memory[a];
endmodule
but problem is compiler says there is nothng avaliable pin for to implemet this.
is there anyone who can help me or anyone have any idea?