Quantcast
Channel: Cadence Custom IC Design Forum
Viewing all articles
Browse latest Browse all 4923

Writing into a file in Verilog-A Model

$
0
0

Dear All,

I want to write the data into a file in the Verilog-A model.

I tried something like below.  It is not showing any errors, but the file is still empty. By the way, reading from this file works great. 

`include "constants.vams"

`include "disciplines.vams"

integer fd;

real r_file = 0.001;

analog beginfd = $fopen("./my_file.txt", "w");

$fwrite(fd, "%e", r_file);

//outp = $fscanf(fd, "%e", r_file);

$fclose(fd);

end

endmodule

I also tried $fdisplay but the result didn't change. 


Viewing all articles
Browse latest Browse all 4923

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>