# youssef-fd/axi-based-dma-design architecture

> Architecture diagram of the GitHub repository youssef-fd/axi-based-dma-design, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/youssef-fd/axi-based-dma-design
- Repository: https://github.com/youssef-fd/axi-based-dma-design

## Overview

This repository implements a memory-to-memory AXI4 DMA engine. The documented workflow is: a host supplies transfer parameters and starts the engine; the controller triggers read and write masters; the read master fetches source bursts into an internal FIFO, and the write master drains it to the destination. The README also describes AXI slave behavior and error propagation, but the available material contains no source excerpts, so those components are shown without speculative connections. Relationships below are limited to those explicitly documented.

Main entry points: [`hdl/dma_engine.sv`](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/dma_engine.sv) (DMA engine), [`hdl/AXI_Read_MASTER/axi_read-master.sv`](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Read_MASTER/axi_read-master.sv) (AXI read master), [`hdl/AXI_Write_MASTER/axi_write_master.sv`](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Write_MASTER/axi_write_master.sv) (AXI write master), [`hdl/DMA_Controller/dma_controller.sv`](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/DMA_Controller/dma_controller.sv) (DMA controller)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_control["Transfer control"]
  node_controller["DMA controller<br/>[dma_controller.sv]"]
end

subgraph group_datapath["DMA datapath"]
  node_engine["DMA engine<br/>[dma_engine.sv]"]
  node_fifo["Transfer FIFO<br/>[dma_engine.sv]"]
end

subgraph group_interfaces["AXI interfaces"]
  node_read_master["AXI read master<br/>[axi_read-master.sv]"]
  node_write_master["AXI write master"]
  node_read_fifo["Read FIFO<br/>[FIFO.sv]"]
  node_write_fifo["Write FIFO<br/>[FIFO.sv]"]
  node_ram_slave["AXI RAM slave<br/>[axi_RAM_slave.sv]"]
end

node_host(("Host processor"))
node_read_memory[("Source memory space")]
node_write_memory[("Destination memory space")]

node_host -->|"configures and starts"| node_engine
node_engine -->|"integrates"| node_controller
node_engine -->|"integrates"| node_read_master
node_engine -->|"integrates"| node_write_master
node_engine -->|"integrates"| node_fifo
node_controller -->|"triggers read"| node_read_master
node_controller -->|"triggers write"| node_write_master
node_read_master -->|"pushes data"| node_fifo
node_fifo -->|"supplies data"| node_write_master
node_read_master -->|"reads bursts"| node_read_memory
node_write_master -->|"writes bursts"| node_write_memory

click node_engine "https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/dma_engine.sv"
click node_controller "https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/DMA_Controller/dma_controller.sv"
click node_read_master "https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Read_MASTER/axi_read-master.sv"
click node_write_master "https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Write_MASTER/axi_write_master.sv"
click node_fifo "https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/dma_engine.sv"
click node_read_fifo "https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Read_MASTER/FIFO.sv"
click node_write_fifo "https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Write_MASTER/FIFO.sv"
click node_ram_slave "https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/axi_RAM_slave.sv"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_controller toneBlue
class node_engine,node_fifo,node_read_memory,node_write_memory toneAmber
class node_read_master,node_write_master,node_read_fifo,node_write_fifo,node_ram_slave toneMint
class node_host toneIndigo
```

## Components

### Transfer control

- [DMA controller](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/DMA_Controller/dma_controller.sv): `hdl/DMA_Controller/dma_controller.sv`

### DMA datapath

- [DMA engine](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/dma_engine.sv): `hdl/dma_engine.sv`
- [Transfer FIFO](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/dma_engine.sv): `hdl/dma_engine.sv`

### AXI interfaces

- [AXI read master](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Read_MASTER/axi_read-master.sv): `hdl/AXI_Read_MASTER/axi_read-master.sv`
- [AXI write master](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Write_MASTER/axi_write_master.sv): `hdl/AXI_Write_MASTER/axi_write_master.sv`
- [Read FIFO](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Read_MASTER/FIFO.sv): `hdl/AXI_Read_MASTER/FIFO.sv`
- [Write FIFO](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/AXI_Write_MASTER/FIFO.sv): `hdl/AXI_Write_MASTER/FIFO.sv`
- [AXI RAM slave](https://github.com/youssef-fd/axi-based-dma-design/blob/main/hdl/axi_RAM_slave.sv): `hdl/axi_RAM_slave.sv`

### Other components

- **Host processor**
- **Source memory space**
- **Destination memory space**

## Connections

- Host processor → DMA engine: configures and starts (evidence: `README.md`)
- DMA engine → DMA controller: integrates (evidence: `README.md`)
- DMA engine → AXI read master: integrates (evidence: `README.md`)
- DMA engine → AXI write master: integrates (evidence: `README.md`)
- DMA engine → Transfer FIFO: integrates (evidence: `README.md`)
- DMA controller → AXI read master: triggers read (evidence: `README.md`)
- DMA controller → AXI write master: triggers write (evidence: `README.md`)
- AXI read master → Transfer FIFO: pushes data (evidence: `README.md`)
- Transfer FIFO → AXI write master: supplies data (evidence: `README.md`)
- AXI read master → Source memory space: reads bursts (evidence: `README.md`)
- AXI write master → Destination memory space: writes bursts (evidence: `README.md`)
