Vanessa,
You cannot initialize an entire array in one statement. Below is a
version that vl2mv does read.
Roderick
module memory(clk,rw,inx,di,do);
//parameter n=2,m=2;
input clk,rw;
input [2:1] inx;
input [1:0] di;
output [1:0] do;
reg [1:0] do;
reg [1:0] file [1:0];
initial begin
file[0]=0;
file[1]=0;
do = 0;
end
always @ (negedge clk)
if (rw)
do=file[inx];
else
file[inx]=di;
endmodule
a a wrote:
>
> dear sir
> while operating "read_blif_mv" on following code error
> coming is "variable file raw_n0....... is not defined
> as an outputof a table in model memory".
> what modification is required?
> ****************************************************
> module memory(clk,rw,inx,di,do);
> //parameter n=2,m=2;
> input clk,rw;
> input [2:1] inx;
> input [1:0] di;
> output [1:0] do;
> reg [1:0] do;
> reg [1:0] file [1:0];
> initial file=0;
> initial do=0;
> always @ (negedge clk)
> if (rw) do=file[inx];
> else file[inx]=di;
> endmodule
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Auctions - buy the things you want at great prices
> http://auctions.yahoo.com/
This archive was generated by hypermail 2b30 : Mon May 21 2001 - 09:27:49 MDT