
VLSI
Design and Implementation of an AMBA APB Bridge Interface Using Verilog HDL
Abstract:
This project focuses on designing and implementing an AMBA Advanced Peripheral Bus (APB) Bridge Interface using Verilog HDL. The APB bridge connects a high-performance system bus, such as AHB or AXI, to low-power peripheral devices using the APB protocol. It converts incoming bus requests into APB-compatible read and write transactions. A Finite State Machine (FSM) controls the setup and access phases, manages handshake signals, and ensures reliable communication between the system bus and peripheral devices.
Project Description:
The project develops an APB Bridge Controller consisting of request-handling logic, an FSM, address and data registers, control-signal generation logic, and response-handling logic.
The bridge receives requests from a high-performance bus interface and converts them into APB transactions.
Important APB signals include:
- PCLK: APB clock signal.
- PRESETn: Active-low reset signal.
- PADDR: Peripheral address bus.
- PWRITE: Selects read or write operation.
- PSEL: Selects the target peripheral.
- PENABLE: Indicates the access phase.
- PWDATA: Data sent from the bridge to the peripheral.
- PRDATA: Data returned from the peripheral.
- PREADY: Indicates that the peripheral has completed the transaction.
The bridge follows three main FSM states:
- IDLE: Waits for a valid system-bus request.
- SETUP: Asserts PSEL and provides the address and control information.
- ACCESS: Asserts PENABLE and waits for PREADY before completing the transaction.
The design can support both read and write operations with configurable address and data widths.
Working Principle:
1. The bridge initializes in the IDLE state after reset.
2. The high-performance bus provides a valid read or write request.
3. The bridge captures the address, data, and control information.
4. The FSM transitions from IDLE to SETUP.
5. During SETUP, the bridge asserts PSEL and places the address and control signals on the APB interface.
6. The FSM transitions to ACCESS and asserts PENABLE.
7. For a write operation, PWDATA carries the data to the selected peripheral.
8. For a read operation, PRDATA carries the data returned by the peripheral.
9. The bridge monitors PREADY and remains in ACCESS while the peripheral is not ready.
10. When PREADY becomes active, the transaction completes and the bridge generates a response to the upstream bus.
11. The controller deasserts the APB control signals and returns to IDLE or accepts the next request.
Notes:
- Use Verilog HDL for RTL implementation.
- Implement the controller using a clearly defined three-state FSM.
- Support both APB read and write transactions.
- Use configurable address and data widths.
- Keep PSEL active throughout the SETUP and ACCESS phases of a transaction.
- Assert PENABLE only during the ACCESS phase.
- Ensure address and control signals remain stable during the required APB phases.
- Handle PREADY correctly, including wait states.
- Implement suitable response handling for the upstream AHB/AXI interface.
- Use active-low reset through PRESETn.
- Verify read, write, reset, and peripheral wait-state scenarios.
- Check back-to-back transactions and peripheral response timing.
- Tools may include ModelSim, QuestaSim, Vivado, Quartus, and Icarus Verilog.
- Optional enhancements include multiple APB peripheral selection, error-response handling, configurable bus widths, and support for different APB versions.
- A complete AHB-to-APB or AXI-to-APB bridge requires the corresponding upstream protocol handshake and response logic; the APB FSM alone is not a complete bus bridge.
- Follow the applicable AMBA APB specification for signal timing and protocol compliance.
Expected Outcome:
The expected outcome is a functional AMBA APB Bridge Interface capable of converting upstream system-bus requests into APB read and write transactions. The controller correctly manages IDLE, SETUP, and ACCESS phases, generates APB control signals, and handles peripheral readiness through PREADY. The project demonstrates FSM-based bus control, protocol conversion, handshake management, Verilog RTL implementation, and simulation-based verification for SoC and FPGA peripheral integration.
All Projects




