Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
14 years ago

write to segment (multiple locations) of memory

Please see post# 6 for a better formulation of the problem.

------

Hi!

I have a question about the memory blocks that are available on the Altera FPGA chips.

Is it possible to write the same data to multiple locations of a memory block?

Example:

I want to write the value 7 to locations 0, 1, 2, and 3 of the memory block.

I want to do it in one clock cycle.

It is possible to do in ASIC with a custom memory controller.

Is it possible in FPGA?

Alex

12 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    Writing same value or different values does not make it any easier for ram access. There are as many ports as vendors have decided.

    I believe you better use register array indexed as ram

    --- Quote End ---

    [1]

    You are right if you consider the M9K, M144K to be RAMs. Somehow I thought these are generic memory blocks that can implement various types of memory: random access, FIFO, etc.

    [2]

    What is the most detailed information about the M9K (and the like) memory blocks available? I have the stratix iv hanbook (http://www.altera.com/literature/hb/stratix-iv/stratix4_handbook.pdf) (chapter 3), but it still does not answer all my questions.

    [QUESTION I STILL HAVE]

    1. How do I write VHDL code to tell Quartus tools to put a certain memory into a M9K, or M144K, or other block?
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi,

    memory blocks are -as you certainly know - are ASIC like memory structures within fpgas accessible to logic through their ports and configurable through megawizard or code... into rams or roms or fifos or shift function.

    I don't know what you mean exactly by memory block as opposed to these blocks. a ram has access through its ports, so is the rom and so is fifo or shift function.

    You will need to click on megawizard (tool menu) and choose memory compiler then choose your configuration.