RTL Studio Open IDE

1.4 · SOC CLASS

AXI-Lite decode wrapper

Implement an AXI-Lite decode wrapper to route AW/AR addresses to multiple slaves and mux B/R responses.

Video coming soon. This lesson page stays at the same URL when the lecture publishes.

What you practice

AXI-Lite decode wrapper (1.4). Implement an AXI-Lite decode wrapper to route AW/AR addresses to multiple slaves and mux B/R responses. It is in AXI-Lite Decode Wrapper — Part 1 · Address Map & Decode of the SoC Masterclass. Turn a memory map into combinational decode, one-hot selects, and an AXI-Lite fabric.

SoC lessons simulate the fabric and the peripheral together in the IDE. Verilator is the simulator; the waveform is where address and response show up.

What you will learn

This lesson covers the implementation of an AXI-Lite decode wrapper. You will route address and data channels to multiple slave interfaces. You will also mux response channels back to the master.

Learning objectives

  • Understand address decoding for multiple AXI-Lite slaves.
  • Implement slave selection logic based on address hits.
  • Route AW and AR channels to the correct slave interface.
  • Mux B and R responses back to the main AXI interface.

Theory

An AXI-Lite decode wrapper acts as a bridge between a master and multiple slaves. The wrapper uses an address decoder to determine which slave owns a specific address. It then routes the address and data signals to that specific slave. The wrapper must also handle the response signals from the selected slave. This allows a single master to communicate with many peripherals efficiently.

SignalDirectionDescription
awaddrInputAddress for write transfer
awvalidInputWrite address valid signal
awreadyOutputWrite address ready signal
wdataInputWrite data payload
wvalidInputWrite data valid signal
brespOutputWrite response status
araddrInputAddress for read transfer
arvalidInputRead address valid signal
rrespOutputRead response status

The decode logic typically compares the incoming address against predefined memory maps. A hit signal indicates which slave should respond. The wrapper then enables the valid signals for that specific slave. The ready signal from the master is driven by the ready signal of the selected slave.

Practice

Open RtlStudio and select this chapter in the Examples or Lecture list. Confirm that the files appear in the Explore tree. Open student/rtl/ip/soc/axi_lite_decode_wrapper.sv from the Explore panel. You need to implement the address routing for the AW channel. The testbench checks if the AW channel is granted for a specific address. You must assign the s.awaddr to all slave awaddr ports. The testbench expects the wrapper to route the address correctly to enable the slave selection logic. Open student/tb/tb_top.sv to verify the testbench stimulus. Run the simulation from the sidebar. Check the Log panel for the INFO lines. The simulation should complete successfully if the address routing is correct.

Summary

You implemented an AXI4-Lite address decoder to route write and read address channels to multiple slave interfaces. The design includes logic to mux response channels back to the master and handle unmapped address errors. This exercise demonstrated how to build a reusable wrapper for complex System-on-Chip interconnects.

© 2026 RtlStudio. Licensed under CC BY-NC-ND 4.0. Commercial use and modifications by third parties are not permitted.

Run it in the Verilog IDE

  1. Open the lesson workspace in the IDE. The fabric and the peripheral are one simulation.
  2. Run Verilator and follow the address, write data, and read response on the waveform.
  3. A passing log is not enough when decode or an IRQ line is the point of the lesson — those show up on the VCD.
  4. Run Yosys on the RTL island you just integrated when you want the mapped cells.

The lesson is done when the simulation matches AXI-Lite decode wrapper. Change the source, run the Verilog simulator again, and read the waveform without leaving the IDE. Simulation guide · Yosys guide.