cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
caiosan
Visitor
Visitor
2,548 Views
Registered: ‎11-30-2017

Reading BRAM in run time

Jump to solution

Hi All,

 

I am trying to read memory in run time. My design has a PUF that saves its responses in the memory at the same address of a challenge. So, my intention is to dump the memory after writing in all addresses. This is easily done with In-content memory editor from Quartus, but I'm having a hard time with ISE 14.1 (my FPGA is a VIRTEX 5).


I tried to use data2mem, but after I generate the new bitfile and load it into the FPGA through the IMPACT, I don't know what do to download the content from the FPGA. I've read what I found of data2mem manual, but none has been clear about runtime dump of the memory.

 

So, my questions are. Is there any way to dump a memory in runtime? Is data2mem this tool?

 

Thank you very much for your attention!

0 Kudos
1 Solution

Accepted Solutions
caiosan
Visitor
Visitor
3,074 Views
Registered: ‎11-30-2017

This is just to help others that may face the same challenge I had.

 

So, I was trying to use runtime memory dump to debug my code. I could not make that work as I thought (like Altera's In-system Memory Content Editor). Thus, I moved on to try other tools. I ended up using ChipScope. I needed only two ChipScope components ILA and ICON and I didn't need to use memory. Actually, ILA uses an internal memory anyway, which one you can dump directly to multiple files. So, if you need and were not able to debug a Memory in runtime using data2mem (as do I), you can use an ILA component to get values at the moment they'll be store in memory.

 

The only thing I don't know and I didn't search about it, it's whether you can update internal values on the FPGA using ChipScope. Nonetheless, I think that by combining ChipScope and Data2Mem you would be able to do any runtime debug you would need.

 

That's all!

View solution in original post

0 Kudos
3 Replies
balkris
Xilinx Employee
Xilinx Employee
2,532 Views
Registered: ‎08-01-2008
This document steps through examples to illustrate how Data2Mem is used. It describes how to write a BMM file, how to check the content of a block RAM in a BIT file, and how to check the content of an ELF file, then verify the contents of the block RAM in the design.

Data2Mem could be used as both standalone and with EDK. This document describes the usage of Data2Mem in both cases.

The main objectives of this document are to provide users with a conceptual background on how and where Data2Mem is used, and also provide a comprehensive description for users to be able to debug Data2Mem issues on their own.
https://www.xilinx.com/Attachment/Xilinx_Answer_46945_Data2Mem_Usage_and_Debugging_Guide.pdf
Thanks and Regards
Balkrishan
--------------------------------------------------------------------------------------------
Please mark the post as an answer "Accept as solution" in case it helped resolve your query.
Give kudos in case a post in case it guided to the solution.
0 Kudos
caiosan
Visitor
Visitor
2,519 Views
Registered: ‎11-30-2017

Hi Balkrishan,

 

I had read this document. But then again, I still don't get values on the fly. I was able to dump the memory before the initialization file. After the initialization and it worked. However, I am not able to read on the fly. There a specific part of the document that says:

 

"One more step of verification can be performed by reading back the data from the hardware from that particular memory location via XMD."

 

I was not able to use XMD. The document shows a picture of using the XMD to read a memory value, but doesn't show the commands to reach that (and the steps I found on the internet did not work). Also, I would like to know how to dump the entire memory at once to a file,  I don't know if XMD can do it.

 

Thanks.

 

0 Kudos
caiosan
Visitor
Visitor
3,075 Views
Registered: ‎11-30-2017

This is just to help others that may face the same challenge I had.

 

So, I was trying to use runtime memory dump to debug my code. I could not make that work as I thought (like Altera's In-system Memory Content Editor). Thus, I moved on to try other tools. I ended up using ChipScope. I needed only two ChipScope components ILA and ICON and I didn't need to use memory. Actually, ILA uses an internal memory anyway, which one you can dump directly to multiple files. So, if you need and were not able to debug a Memory in runtime using data2mem (as do I), you can use an ILA component to get values at the moment they'll be store in memory.

 

The only thing I don't know and I didn't search about it, it's whether you can update internal values on the FPGA using ChipScope. Nonetheless, I think that by combining ChipScope and Data2Mem you would be able to do any runtime debug you would need.

 

That's all!

View solution in original post

0 Kudos