Embedded Design Handbook

ID 683689
Date 8/28/2023
Public
Document Table of Contents

3.6.5.5.2. Add the On-Chip Memory

Processor systems require at least one memory for data and instructions. This design example uses one 20 KB on-chip memory for both data and instructions. To add the memory, perform the following steps:

  1. On the IP Catalog tab (to the left of the System Contents tab), expand Basic Functions, expand On-Chip Memory, and then click On-Chip Memory (RAM or ROM).
  2. Click Add.
    The On-Chip Memory (RAM or ROM) parameter editor appears.
  3. In the Block type list, select Auto.
  4. In the Total memory size box, type 20480 to specify a memory size of 20 KB.
    Do not change any of the other default settings.
  5. Click Finish. You return to Platform Designer.
  6. Click the System Contents tab.
    An instance of the on-chip memory appears in the system contents table.
  7. In the Name column of the system contents table, right-click the on-chip memory and click Rename.
  8. Type onchip_mem and press Enter.
    You must type these tutorial component names exactly as specified. Otherwise, the tutorial programs written for this Nios® II system fail in later steps. In general, it is a good habit to give descriptive names to hardware components. Nios® II programs use these symbolic names to access the component hardware. Therefore, your choice of component names can make Nios® II programs easier to read and understand.