Artoriuz / maestro

A 5 stage-pipeline RV32I implementation in VHDL
MIT License
19 stars 5 forks source link

MISSING "PROGMEM.VHD" #1

Closed ghost closed 4 years ago

ghost commented 4 years ago

Hello,

I am trying to compile all the source files and there is one error which is coming in the "program memory interface" file that "No such design unit as "progmem.vhd".

Thank you, Dhruv Gupta

Artoriuz commented 4 years ago

Hi, the progmem used was is in the repo: https://github.com/Artoriuz/maestro/blob/master/Quartus/riscv_microcontroller/progmem.vhd

You can also generate your own memory using Quartus and its IP-related tools (MegaWizard Plug-In Manager in the older versions I believe).

The vhds I provided should work without any modifications, maybe the "riscv_microcontroller" project file is pointing to the wrong directory, I'll check this when possible.

Thanks for the contact!

Artoriuz commented 4 years ago

I've just tested it on Quartus Prime 20.1 Lite Edition, and it worked fine with a clean download of the repo. I did "update" the memory module in Project Navigator -> IP Components so it matched the correct version of Quartus, but apart from that it should work just fine.

If you run out of memory in your target FPGA you can also make the memories smaller. I'm only using Quartus IP for the program memory because it makes the process of updating the file with actual programs much simpler within Quartus itself, but as you can probably see the datamem vhds were not generated by Quartus.

Quartus memory has the disadvantage of enforcing an address register in its input, which creates a single cycle delay for you to actually be able to get an output from memory. The progmem interface takes this into account and has some comments on how to use it with unregistered memory, if you're not using Quartus this is probably a good idea.

In any case, since the file is present in the repo and the readme clearly states it was created by Quartus Prime 18.1 for the Cyclone IV GX FPGA family (meaning you need to update the module if you want to use it with anything else) I'll be closing this as solved. Feel free to ask anything else if you run into problems =).

Cordially, João Vitor Rafael Chrisóstomo.