Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.
Want to store values from a text file into an multi dimensional array in sys verilog
I have a text file and the name of the file is named.txt. In this file following values are written.
I want to store this values in a 4X4 multidimensional array. How can i do this. Please help me.
Thanks in...
I have written the following code in system verilog in Modelsim.
module mul_array ();
byte md[2:1][3:1]='{'{0,1,2},'{3,4,5}};
initial begin
$display ("Initial value:");
foreach (md [i,j])
$display ("md[%0d] [%0d]=%0d", i,j, md[i][j]);
end
endmodule
I have declared the...
Hello
I can not declare a multidimensional array in modelsim for systemverilog. Here's the code
module TwoD_Array ();
bit [7:0] array[1:2][1:4];
initial begin
/* array [0][0]=8'd50;
array [0][1]=8'd60;
array [1][0]=8'd70;
array [1][1]=8'd90; */...
Hello
I have the following code in Modelsim 10.1b.
module TwoD_Array ();
reg array [3:0] [7:0]; //={1010, 1110, 1111,1011};
initial begin
array [0][1]=11001101; //{{11001101}|{11110101}|{10101111}|{11100111}};
//array = '{{8'b0},{8'b1},{8'b0},{8'b1}};
//$display...
Dear ads-ee,
Thanks for your reply. I got the first one. The 2nd one mentions that gray scale image have only the intensity of the RGB value. Suppose an image (8 bit gray scale image) has only 256 pixels. I have to convert all the pixels into its related 8bit value. 1st pixel value is 48 so it...
Dear vGoodTimes,
Thanks for your good suggestions.
Now i am explaining the idea to you. I have a ram that i have designed in altera quertus.
The code is as follows.
module ram_8bit (we,re, clk, add, datin, datout);
input [6:0] add;
input we, re, clk;
input [7:0] datin;
output[7:0] datout...
Dear ads-ee
Actually this is not like that you are thinking. I am doing it for my own. There is no transaction regarding this issue. By the way, thank you for your advice.
Thanks to andre_teprom. You also mentioned the right thing. I have to study more.
Again thank you very much andre_teprom.
Actually i have to do a job related to water marking. On that project, there is also a encoder. On that encoder part, i have take the grey image and convert the image to its pixels. That's why i have to take a gray scale test 8bit image into a ram. From...
Thanks a lot for replying TrickyDicky.
The specific question is that i want to convert gray scale image into pixels and store it into a RAM which is designed in Altera cyclone II code.
And the image conversion code should be in Altera. Please help me regarding this issue.
Thanks in advance.
Dear All
I want to convert an image to its pixel value in FPGA system like altera. In this system i had to read the pixels very often. Can any one help me what kind of altera devices are needed so that i can input an image on that FPGA based device the device will give me pixel value in RAM...
Hi i have a problem in my qpsk code in matlab that is given below
plot(abs([Qpsk Qpsk_r])),axis([0 Ns -1 16]),
legend('AWGN','RAYLEIGH'),
title('QPSK in AWGN & Rayleigh fading channel')
It shows the warning below
Warning: Ignoring extra legend entries.
> In legend at 290
In uhguasijfgdfjuf...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.