FPGA, CPLD, and ASIC solutions from Altera
  • Download Center
  • Literature
Sign in/register
myAltera Account
Welcome
  •   myAltera
  •   Logout
  • Products
    • Devices
    • Design Software
    • Intellectual Property
    • Development Kits/Cables
    • Design & Support Services
    • Literature
  • End Markets
    • Automotive
    • Broadcast
    • Computer & Storage
    • Consumer
    • Industrial
    • Medical
    • Military
    • Test & Measurement
    • Wireless
    • Wireline
  • Technology
    • DSP
    • External Memory
    • Embedded Processing
    • Transceivers
    • Parallel I/O
    • Signal Integrity
    • System Integration
  • Training
    • Training Courses
    • University Program
    • Webcasts & Videos
    • Demonstrations
    • Events Calendar
  • Support
    • Design & Support Resources
    • Knowledge Database
    • Devices
    • Design Software
    • Intellectual Property
    • Development Kits/Cables
    • Design Examples
    • Downloads
    • User Communities/Forums
    • mySupport
  • About Altera
    • About Us
    • Environmental
    • Customer Successes
    • Partners
    • Newsroom
    • Investor Relations
    • Jobs
    • Contact Us
  • Buy Online
    • Devices
    • Design Software
    • Development & Education Kits
    • Cables & Programming Hardware
    • Intellectual Property
  • Entire Site
  • Part Number
  • Knowledge Database
  • Support & Technical Docs
  • Forums & Wiki
Username:  
Password:  
 
Forgot my username or password
Don't have myAltera account? Register Now.
Enter your email address:

Avalon Memory-Mapped Slave Template

Home > Support > Design Examples > Nios II > Avalon Memory-Mapped Slave Template

Related Links

  • Avalon Interface Specifications
  • Component Interface Tcl Reference
  • System Interconnect Fabric for Memory-Mapped Interfaces
  • Embedded Design Handbook: Avalon Memory-Mapped Design Optimizations

The template provided contains an Avalon® Memory-Mapped (MM) Verilog module bundled as an SOPC Builder-ready component. The component is parameterizable, allowing you to select functionality on a per-register basis. You can use the component with any Altera® device family supported by SOPC Builder. The component is Verilog based, so you can add your own functionality or simply use it as a reference. For ease of use, the component uses Tcl callbacks to allow you to make setting changes automatically in a GUI environment.

You can use this component as a replacement for the PIO component that is available from SOPC Builder. This component implements the same logic, but it is duplicated for up to 16 I/O pairs. This component also supports data widths ranging from 8 to 1,024 bits with an optional loopback mode to allow software developers to readback the output contents. Version 2.0 of this component supports input ports (or read register files) with interrupt capabilities for data widths ranging from 8 to 32 bits. Interrupts are generated by the rising edge data toggle at the input ports.

Figure 1. Component Block Diagram

Figure 1.  Component Block Diagram
View Full Size

Each I/O pair is capable of the access types shown in Table 1.

Table 1. Component Modes
Mode Description
Output Only Output register exposed at top level, input is disabled
Input Only Input register exposed at top level, output is disabled
Output and Input Output and input registers exposed at top level
Output with Loopback Output register exposed at top level, output register supports reads, input is disabled
Disabled Output and input is disabled

The component also optionally provides synchronization signals that you can use to determine when an Avalon-MM master accesses one of the registers. For example, your own custom logic connected to one of the output data ports can use the synchronization signals to signify that the data is valid. Another example is one of the inputs could be connected to a FIFO buffer. The user_chipselect and user_read signals could be used as the read acknowledge signal for the FIFO buffer.

Using This Design Example

  • Download the Avalon-MM Slave Template (.zip).
    • The .zip file contains all the necessary hardware files to reproduce the example.
  • Download the Avalon-MM Slave Template README (.txt).

The use of this design is governed by, and subject to, the terms and conditions of the Altera Hardware Reference Design License Agreement.

Design Examples Disclaimer

These design examples may only be used within Altera Corporation devices and remain the property of Altera. They are being provided on an “as-is” basis and as an accommodation; therefore, all warranties, representations, or guarantees of any kind (whether express, implied, or statutory) including, without limitation, warranties of merchantability, non-infringement, or fitness for a particular purpose, are specifically disclaimed. Altera expressly does not recommend, suggest, or require that these examples be used in combination with any other product not provided by Altera.

Rate This Page


  • Products
    • MAX/MAX II
    • Stratix/Stratix GX
    • Nios II
  • Functionality
    • Arithmetic
    • External Memory Interfaces
    • On-Chip Memory
    • Bus & I/O Functions
    • Logic
    • Interfaces & Peripherals
    • DSP
    • Communications
    • PLL & Clocking
  • Design Entry
    • Quartus II
    • Tcl
    • VHDL
    • Verilog HDL
    • C Code
    • DSP Builder
    • TimeQuest
    • On-Chip Debugging
      • SignalTap II
  • Simulation Tools
    • Mentor Graphics ModelSim
    • Cadence NCsim
    • Synopsys VCS
  • Legacy Examples
    • Graphic Editor
    • AHDL
    Please give us feedback
    Products | End Markets | Technology | Training | Support | About Altera | Buy Online
    Jobs | Investor Relations | Contact Us | Site Map | Privacy | Legal Notice
    Copyright © 1995-2010 Altera Corporation. All Rights Reserved.
    Altera Forum
    Altera
    Forum
    Twitter
    Twitter
    RSS
    RSS
    Facebook
    Facebook
    Flickr
    Flickr
    YouTube
    YouTube
    Email Updates
    Email
    Updates