# gilbert7545/fpga-pynqz2-projects architecture

> Architecture diagram of the GitHub repository gilbert7545/fpga-pynqz2-projects, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-05). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/gilbert7545/fpga-pynqz2-projects
- Repository: https://github.com/gilbert7545/fpga-pynqz2-projects

## Overview

This small FPGA image-inversion project takes a grayscale image, sends each pixel to an AXI4-Lite IP on the PYNQ-Z2, waits for the inverted pixel, then displays and saves the result. The Python excerpt shows the register interaction; the Verilog file is present in the tree, but its implementation was not sampled, so the hardware’s internal behavior is not detailed here.

Main entry points: [`Image_Inversion/invert.py`](https://github.com/gilbert7545/fpga-pynqz2-projects/blob/main/Image_Inversion/invert.py) (Image processing), [`Image_Inversion/invert_module.v`](https://github.com/gilbert7545/fpga-pynqz2-projects/blob/main/Image_Inversion/invert_module.v) (Inversion IP)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_software["Image workflow"]
  node_python_workflow["Image processing<br/>[invert.py]"]
end

subgraph group_hardware["FPGA hardware"]
  node_inversion_ip["Inversion IP<br/>[invert_module.v]"]
end

node_user(("User"))
node_input_image["Input image"]
node_output_image["Inverted image"]

node_user -->|"runs"| node_python_workflow
node_python_workflow -->|"loads"| node_input_image
node_python_workflow -->|"writes pixels"| node_inversion_ip
node_inversion_ip -->|"returns pixels"| node_python_workflow
node_python_workflow -->|"displays and saves"| node_output_image

click node_python_workflow "https://github.com/gilbert7545/fpga-pynqz2-projects/blob/main/Image_Inversion/invert.py"
click node_inversion_ip "https://github.com/gilbert7545/fpga-pynqz2-projects/blob/main/Image_Inversion/invert_module.v"

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_python_workflow,node_user toneBlue
class node_inversion_ip toneAmber
class node_input_image,node_output_image toneIndigo
```

## Components

### Image workflow

- [Image processing](https://github.com/gilbert7545/fpga-pynqz2-projects/blob/main/Image_Inversion/invert.py): `Image_Inversion/invert.py`

### FPGA hardware

- [Inversion IP](https://github.com/gilbert7545/fpga-pynqz2-projects/blob/main/Image_Inversion/invert_module.v): `Image_Inversion/invert_module.v`

### Other components

- **User**
- **Input image**
- **Inverted image**

## Connections

- User → Image processing: runs
- Image processing → Input image: loads (evidence: `Image_Inversion/invert.py`)
- Image processing → Inversion IP: writes pixels (evidence: `Image_Inversion/invert.py`)
- Inversion IP → Image processing: returns pixels (evidence: `Image_Inversion/invert.py`)
- Image processing → Inverted image: displays and saves (evidence: `Image_Inversion/invert.py`)
