# eolab-2025/syntzula architecture

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

- Interactive diagram: https://gitdiagram.com/eolab-2025/syntzula
- Repository: https://github.com/eolab-2025/syntzula

## Overview

SYNtzulA is an ASIC hardware platform for near-sensor spiking-neural-network inference. Its documented processing path encodes continuous signals as spikes, computes inference in a dual- or quad-core SNN accelerator, and uses a RISC-V softcore for system control. The sampled EMG firmware loads weights and samples through SPI, waits for inference, and transmits results over UART. README statements support the major hardware stages; RTL internals were not sampled, so the graph avoids asserting unverified module-to-module calls.

Main entry points: [`firmware/src/applications/emg/main.c`](https://github.com/eolab-2025/syntzula/blob/main/firmware/src/applications/emg/main.c) (EMG firmware), [`rtl/syntzulu_dual_core/delta_modulator_multichannel.v`](https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/delta_modulator_multichannel.v) (Delta spike encoder), [`rtl/syntzulu_dual_core/Syntzulu.sv`](https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/Syntzulu.sv) (Dual-core SNN), [`rtl/syntzulu_quad_core/Syntzulu.sv`](https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_quad_core/Syntzulu.sv) (Quad-core SNN)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_control["Control and firmware"]
  node_riscv["RISC-V core<br/>[serv_top.v]"]
  node_firmware["EMG firmware<br/>[main.c]"]
  node_csr["CSR access<br/>[riscv-csr.h]"]
  node_interrupts["Interrupt definitions<br/>[riscv-interrupts.h]"]
  node_timer["Timer driver<br/>[timer.c]"]
  node_boot["Boot loader<br/>[ROM.c]"]
end

subgraph group_io["Peripheral interfaces"]
  node_peripherals["MMIO map<br/>[peripherals.h]"]
  node_spi["SPI interface<br/>[spi_master.v]"]
  node_uart["UART interface"]
end

subgraph group_encoding["Spike encoding"]
  node_encoder["Delta spike encoder"]
  node_encoding_slot["Encoding slots"]
end

subgraph group_compute["SNN compute"]
  node_dual["Dual-core SNN<br/>[Syntzulu.sv]"]
  node_quad["Quad-core SNN<br/>[Syntzulu.sv]"]
  node_network["SNN layers<br/>[snn_lp.sv]"]
  node_weights[("Weight memories<br/>[weight_mem_ihp.v]")]
  node_ram[("IHP RAM<br/>[ihp_ram.v]")]
end

node_engineer(("Input samples"))

node_engineer -->|"supplies signals"| node_encoder
node_encoder -->|"produces spikes"| node_dual
node_encoder -->|"produces spikes"| node_quad
node_firmware -->|"accesses MMIO"| node_peripherals
node_firmware -.->|"starts SPI transfers"| node_spi
node_firmware -.->|"sends results"| node_uart
node_firmware -->|"loads and reads inference"| node_dual
node_firmware -->|"loads and reads inference"| node_quad
node_riscv -->|"runs control program"| node_firmware
node_firmware -->|"sets sample timer"| node_timer
node_firmware -->|"configures interrupts"| node_csr
node_firmware -->|"uses interrupt masks"| node_interrupts
node_firmware -.->|"loads weights"| node_weights
node_dual -.->|"runs inference"| node_network
node_quad -.->|"runs inference"| node_network

click node_riscv "https://github.com/eolab-2025/syntzula/blob/main/rtl/serv/serv_top.v"
click node_firmware "https://github.com/eolab-2025/syntzula/blob/main/firmware/src/applications/emg/main.c"
click node_csr "https://github.com/eolab-2025/syntzula/blob/main/firmware/src/riscv-csr.h"
click node_interrupts "https://github.com/eolab-2025/syntzula/blob/main/firmware/src/riscv-interrupts.h"
click node_timer "https://github.com/eolab-2025/syntzula/blob/main/firmware/src/timer.c"
click node_boot "https://github.com/eolab-2025/syntzula/blob/main/firmware/src/ROM.c"
click node_peripherals "https://github.com/eolab-2025/syntzula/blob/main/firmware/src/peripherals.h"
click node_spi "https://github.com/eolab-2025/syntzula/blob/main/rtl/servant/spi_master.v"
click node_uart "https://github.com/eolab-2025/syntzula/blob/main/rtl/servant/SerialTransmitter.v"
click node_encoder "https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/delta_modulator_multichannel.v"
click node_encoding_slot "https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/encoding_slot_emg.sv"
click node_dual "https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/Syntzulu.sv"
click node_quad "https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_quad_core/Syntzulu.sv"
click node_network "https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/snn_lp.sv"
click node_weights "https://github.com/eolab-2025/syntzula/blob/main/rtl/memorie_ihp/weight_mem_ihp.v"
click node_ram "https://github.com/eolab-2025/syntzula/blob/main/rtl/memorie_ihp/ihp_ram.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_riscv,node_firmware,node_csr,node_interrupts,node_timer,node_boot toneBlue
class node_peripherals,node_spi,node_uart toneAmber
class node_encoder,node_encoding_slot toneMint
class node_dual,node_quad,node_network,node_weights,node_ram toneRose
class node_engineer toneIndigo
```

## Components

### Control and firmware

- [RISC-V core](https://github.com/eolab-2025/syntzula/blob/main/rtl/serv/serv_top.v): `rtl/serv/serv_top.v`
- [EMG firmware](https://github.com/eolab-2025/syntzula/blob/main/firmware/src/applications/emg/main.c): `firmware/src/applications/emg/main.c`
- [CSR access](https://github.com/eolab-2025/syntzula/blob/main/firmware/src/riscv-csr.h): `firmware/src/riscv-csr.h`
- [Interrupt definitions](https://github.com/eolab-2025/syntzula/blob/main/firmware/src/riscv-interrupts.h): `firmware/src/riscv-interrupts.h`
- [Timer driver](https://github.com/eolab-2025/syntzula/blob/main/firmware/src/timer.c): `firmware/src/timer.c`
- [Boot loader](https://github.com/eolab-2025/syntzula/blob/main/firmware/src/ROM.c): `firmware/src/ROM.c`

### Peripheral interfaces

- [MMIO map](https://github.com/eolab-2025/syntzula/blob/main/firmware/src/peripherals.h): `firmware/src/peripherals.h`
- [SPI interface](https://github.com/eolab-2025/syntzula/blob/main/rtl/servant/spi_master.v): `rtl/servant/spi_master.v`
- [UART interface](https://github.com/eolab-2025/syntzula/blob/main/rtl/servant/SerialTransmitter.v): `rtl/servant/SerialTransmitter.v`

### Spike encoding

- [Delta spike encoder](https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/delta_modulator_multichannel.v): `rtl/syntzulu_dual_core/delta_modulator_multichannel.v`
- [Encoding slots](https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/encoding_slot_emg.sv): `rtl/syntzulu_dual_core/encoding_slot_emg.sv`

### SNN compute

- [Dual-core SNN](https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/Syntzulu.sv): `rtl/syntzulu_dual_core/Syntzulu.sv`
- [Quad-core SNN](https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_quad_core/Syntzulu.sv): `rtl/syntzulu_quad_core/Syntzulu.sv`
- [SNN layers](https://github.com/eolab-2025/syntzula/blob/main/rtl/syntzulu_dual_core/snn_lp.sv): `rtl/syntzulu_dual_core/snn_lp.sv`
- [Weight memories](https://github.com/eolab-2025/syntzula/blob/main/rtl/memorie_ihp/weight_mem_ihp.v): `rtl/memorie_ihp/weight_mem_ihp.v`
- [IHP RAM](https://github.com/eolab-2025/syntzula/blob/main/rtl/memorie_ihp/ihp_ram.v): `rtl/memorie_ihp/ihp_ram.v`

### Other components

- **Input samples**

## Connections

- Input samples → Delta spike encoder: supplies signals (evidence: `README.md`)
- Delta spike encoder → Dual-core SNN: produces spikes (evidence: `README.md`)
- Delta spike encoder → Quad-core SNN: produces spikes (evidence: `README.md`)
- EMG firmware → MMIO map: accesses MMIO (evidence: `firmware/src/applications/emg/main.c`)
- EMG firmware → SPI interface: starts SPI transfers
- EMG firmware → UART interface: sends results
- EMG firmware → Dual-core SNN: loads and reads inference (evidence: `README.md`)
- EMG firmware → Quad-core SNN: loads and reads inference (evidence: `README.md`)
- RISC-V core → EMG firmware: runs control program (evidence: `README.md`)
- EMG firmware → Timer driver: sets sample timer (evidence: `firmware/src/applications/emg/main.c`)
- EMG firmware → CSR access: configures interrupts (evidence: `firmware/src/applications/emg/main.c`)
- EMG firmware → Interrupt definitions: uses interrupt masks (evidence: `firmware/src/applications/emg/main.c`)
- EMG firmware → Weight memories: loads weights
- Dual-core SNN → SNN layers: runs inference
- Quad-core SNN → SNN layers: runs inference
