cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
j1398830
Newbie
Newbie
1,107 Views
Registered: ‎05-18-2018

pre_load_mem_from_file format?

Jump to solution

Hi, according to the Zynq-7000 All Programmable SoC Verification IP v1.0 documentation, pre_load_mem_from_file will "preload" the DDR memory based on a file. (I assume memory can be "preloaded" at any time, but it's not clear from the documentation...)

 

But what is not clear to me is what file format the function expects. The documentation says "Only hexadecimal data format is supported.", but any form of detail is omitted. Should it be something like?

 

FF

4A

 

etc.? I.e. newlines between each byte? Or something else?

0 Kudos
1 Solution

Accepted Solutions
demarco
Xilinx Employee
Xilinx Employee
1,086 Views
Registered: ‎10-04-2016

 Hi @j1398830,

I tried the pre_load_mem_from_file function with values listed in a text file as shown below and was able to populate memory:

 

805cc000
3e69ad7c
043f5708
f3399ae6
4b915f97
416c4382
24100748
b685c66d
b9d93e73
190cd932
8d31101a
9d78923a
c95e0092
05895b0b

 

Regards,

 

Deanna

-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------

View solution in original post

0 Kudos
3 Replies
demarco
Xilinx Employee
Xilinx Employee
1,087 Views
Registered: ‎10-04-2016

 Hi @j1398830,

I tried the pre_load_mem_from_file function with values listed in a text file as shown below and was able to populate memory:

 

805cc000
3e69ad7c
043f5708
f3399ae6
4b915f97
416c4382
24100748
b685c66d
b9d93e73
190cd932
8d31101a
9d78923a
c95e0092
05895b0b

 

Regards,

 

Deanna

-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------

View solution in original post

0 Kudos
j1398830
Newbie
Newbie
1,072 Views
Registered: ‎05-18-2018

Seems to work here too! Thanks! Maybe the documentation could be clarified by saying that there must be a word per line rather than a byte per line (as one would assume as one input parameter is the number of bytes in the file)?

0 Kudos
mtn3325
Participant
Participant
771 Views
Registered: ‎10-05-2015

Hi,

I know this was long ago but how do you use this API in the system verilog testbench? Thanks.

              pre_load_mem_from_file()

 

Regards,

Michael

0 Kudos