Jump to content
  • 0

How to write or read Nexys4 DDR QSPI Flash


Shaw

Question

Hello,

I am using Nexys4 DDR and Vivado2017.3(Windows).

I want to store some data(instructions) in the qspi flash, and when the board starts, I want to load these data into bram(in the FPGA).

I am designing such a program in assembly language(MIPS). I want to know how I need to write this program. 

Just need to use simple load instructions just like load data from bram? And then, how does the qspi flash controller(AXI IP) convert the load instruction into a spi flash command?

I am a newbie of FPGA, I don't know if my description is clear enough.

Finally, thanks for your help.

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

Looking for an open source flash controller you could use?  You might wish to try this one.  You can find it integrated into several open source ZipCPU projects, to include this one.  That includes not only the flash controller, but also software to read an ELF file and program the flash with it.  The cool thing about all of the above is that you can then run the whole thing through an open source similator.  For example, here's a post showing the difference between using a DMA to copy instructions from flash to RAM, and running the same program from flash memory directly (with an I-cache mind you).

Dan

P.S.  I'm hoping to blog about how to build an I-cache soon enough, so that might be a next blog article on zipcpu.com

Link to comment
Share on other sites

1 hour ago, D@n said:

Looking for an open source flash controller you could use?  You might wish to try this one.  You can find it integrated into several open source ZipCPU projects, to include this one.  That includes not only the flash controller, but also software to read an ELF file and program the flash with it.  The cool thing about all of the above is that you can then run the whole thing through an open source similator.  For example, here's a post showing the difference between using a DMA to copy instructions from flash to RAM, and running the same program from flash memory directly (with an I-cache mind you).

Dan

P.S.  I'm hoping to blog about how to build an I-cache soon enough, so that might be a next blog article on zipcpu.com

Thank you for your reply!

I will first check the blog and projects you gave. 

Waiting for your new blog:lol:

Shaw

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...