help in reading a large text file using verilog....

Status
Not open for further replies.

alangs

Member level 3
Joined
Feb 5, 2010
Messages
57
Helped
3
Reputation
6
Reaction score
3
Trophy points
1,288
Location
india
Activity points
1,681
I am having a large text file which contains only the pixel values of an image.....here i can able to read the pixels using $readmemh system task..... but the prolem is memory......am using only 1000 words of memory as below
reg [31:0] Mem [0:999];
initial $readmemh("pixels.txt",Mem);
By this i can get only 1000 pixles from the text file and i will give these pixels to the next module for furthur processing....then i have to read the next 1000 pixels from the text file and put it in the Mem....similarly i want all the pixels to be readed from the txt file with the Mem size as 1000 and give those to the next module for furthur processing......so how i can do this plz i will be very thank full to u...plz help me.....
 

why don't you use bram instead of reg
 

thanks for yur reply i didnt understand wat u r trying culd u plz explain with simple example...
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…