Forum Discussion

Rodo's avatar
Rodo
Icon for Occasional Contributor rankOccasional Contributor
4 years ago

MAX10, on-board RAM or ROM: What does memory initialization do?

Hi all,

I'm playing with a BeMicroMAX10 that I've had for a while. Last time I used it was in Quartus web (free) v15, now using v21.1.0 (also free).

I was getting an error at compile with error initialization. In the platform designer (old qsys?) I add on-board ROM or RAM and I click the textbox for memory initialization. Anyhow ... I got rid of the error by clicking the box below to give it a name. If I click the boxes or don't click the boxes the total memory bits usage does not change. So, what does memory initialization actually do? I wonder if it really sets the value of each memory cell to a certain hex value? This sounds silly unless it is needed for some reason. When using microcontrollers I always assume the value of uninitialized memory is a random value.

Thanks

11 Replies

  • sstrell's avatar
    sstrell
    Icon for Super Contributor rankSuper Contributor

    It's an FPGA, so you can program the contents of memories with whatever values you want when you program the device. You need to associate a .hex or a .mif file with a particular memory for this to work, and you can do that in the IP parameter editor for the memory or with a synthesis attribute in your HDL code.

    If you don't have a .hex or .mif file, make sure you disable memory initialization in the parameter editor.

  • YEan's avatar
    YEan
    Icon for Contributor rankContributor

    Hi Rodo,

    Do you have any updates on your question?

    Thank you.

    Best regards,

    Ean

      • YEan's avatar
        YEan
        Icon for Contributor rankContributor

        Hi Rodo,

        I think that your issue has been resolved by sstrell.

        I'll now transition this thread to community support.
        If you have a new question, feel free to open a new thread to get the support from Intel experts.

        Thank you.

        Best regards,

        Ean