Continue to Site

Welcome to EDAboard.com

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.

reading and writing a text file in verilog

Status
Not open for further replies.

praveenvanaparthy

Newbie level 6
Joined
Jun 19, 2011
Messages
14
Helped
3
Reputation
6
Reaction score
3
Trophy points
1,283
Activity points
1,376
hi ..
i have a problem of read&write text/doc files in verilog.

i want to read in.txt file and write the data into out.txt .

am using $readmemb("in.txt",w);
and $fopenr("in.txt");
and for writing i open a file=$fopen("out.txt");

the program shows errors.
am write one separate prog for reading, its working.
but i didn't get how to write the same data into other file.

could you give some suggestions and examples.
 

If you are just looking to read in a memory and then write it out, use

$readmemb("in.txt",w);
$writememb("out.txt",w);

If you are getting errors, you need to tell people exactly what those errors are for people to help you.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top