# open-sdr/openofdm architecture

> Architecture diagram of the GitHub repository open-sdr/openofdm, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-29). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/open-sdr/openofdm
- Repository: https://github.com/open-sdr/openofdm

## Overview

OpenOFDM is an 802.11a/g and 802.11n OFDM PHY receiver, primarily implemented as synthesizable Verilog for the USRP N210. The documented runtime path accepts 20-MSPS I/Q samples and produces decoded packet bytes; synchronization, frequency correction, equalization, signaling, and payload decoding are distinct receiver stages. A Python decoder provides cross-validation. The tree exposes the RTL area only as broad directories, so internal hardware links are shown at that level; detailed wiring is not inferred from unsampled RTL.

Main entry points: [`verilog/usrp2`](https://github.com/open-sdr/openofdm/tree/master/verilog/usrp2) (dot11 PHY), [`docs/source/sync_long.rst`](https://github.com/open-sdr/openofdm/blob/master/docs/source/sync_long.rst) (Packet Sync), [`docs/source/freq_offset.rst`](https://github.com/open-sdr/openofdm/blob/master/docs/source/freq_offset.rst) (Frequency Correction), [`docs/source/overview.rst`](https://github.com/open-sdr/openofdm/blob/master/docs/source/overview.rst) (OFDM FFT)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_receiver["OFDM Receiver"]
  node_dot11["dot11 PHY"]
  node_sync["Packet Sync<br/>[sync_long.rst]"]
  node_ltf["Long Training<br/>[sync_long.rst]"]
  node_freq["Frequency Correction<br/>[freq_offset.rst]"]
  node_fft["OFDM FFT<br/>[overview.rst]"]
  node_equalizer["Channel Equalization<br/>[eq.rst]"]
end

subgraph group_decode["Packet Decoding"]
  node_signal["SIGNAL Decode<br/>[sig.rst]"]
  node_data["Payload Decode<br/>[decode.rst]"]
end

subgraph group_validation["Python Validation"]
  node_pydecoder["Python Decoder<br/>[decode.py]"]
  node_commpy["CommPy Algorithms"]
end

node_usrp(("USRP I/Q Source"))
node_bytes["Decoded Bytes"]
node_host(("USRP Host"))
node_samples["Captured Samples"]

node_usrp -->|"streams I/Q"| node_dot11
node_dot11 -->|"detects packets"| node_sync
node_sync -->|"locates training"| node_ltf
node_ltf -->|"estimates offset"| node_freq
node_freq -->|"corrects samples"| node_fft
node_fft -->|"transforms symbols"| node_equalizer
node_equalizer -->|"provides carriers"| node_signal
node_signal -->|"provides parameters"| node_data
node_data -->|"outputs bytes"| node_bytes
node_dot11 -->|"returns packet bytes"| node_host
node_samples -->|"reads samples"| node_pydecoder
node_pydecoder -.->|"uses algorithms"| node_commpy

click node_dot11 "https://github.com/open-sdr/openofdm/tree/master/verilog/usrp2"
click node_sync "https://github.com/open-sdr/openofdm/blob/master/docs/source/sync_long.rst"
click node_ltf "https://github.com/open-sdr/openofdm/blob/master/docs/source/sync_long.rst"
click node_freq "https://github.com/open-sdr/openofdm/blob/master/docs/source/freq_offset.rst"
click node_fft "https://github.com/open-sdr/openofdm/blob/master/docs/source/overview.rst"
click node_equalizer "https://github.com/open-sdr/openofdm/blob/master/docs/source/eq.rst"
click node_signal "https://github.com/open-sdr/openofdm/blob/master/docs/source/sig.rst"
click node_data "https://github.com/open-sdr/openofdm/blob/master/docs/source/decode.rst"
click node_pydecoder "https://github.com/open-sdr/openofdm/blob/master/scripts/decode.py"
click node_commpy "https://github.com/open-sdr/openofdm/tree/master/scripts/commpy"

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_dot11,node_sync,node_ltf,node_freq,node_fft,node_equalizer toneBlue
class node_signal,node_data toneAmber
class node_pydecoder,node_commpy toneMint
class node_usrp,node_bytes,node_host,node_samples toneIndigo
```

## Components

### OFDM Receiver

- [dot11 PHY](https://github.com/open-sdr/openofdm/tree/master/verilog/usrp2): `verilog/usrp2`
- [Packet Sync](https://github.com/open-sdr/openofdm/blob/master/docs/source/sync_long.rst): `docs/source/sync_long.rst`
- [Long Training](https://github.com/open-sdr/openofdm/blob/master/docs/source/sync_long.rst): `docs/source/sync_long.rst`
- [Frequency Correction](https://github.com/open-sdr/openofdm/blob/master/docs/source/freq_offset.rst): `docs/source/freq_offset.rst`
- [OFDM FFT](https://github.com/open-sdr/openofdm/blob/master/docs/source/overview.rst): `docs/source/overview.rst`
- [Channel Equalization](https://github.com/open-sdr/openofdm/blob/master/docs/source/eq.rst): `docs/source/eq.rst`

### Packet Decoding

- [SIGNAL Decode](https://github.com/open-sdr/openofdm/blob/master/docs/source/sig.rst): `docs/source/sig.rst`
- [Payload Decode](https://github.com/open-sdr/openofdm/blob/master/docs/source/decode.rst): `docs/source/decode.rst`

### Python Validation

- [Python Decoder](https://github.com/open-sdr/openofdm/blob/master/scripts/decode.py): `scripts/decode.py`
- [CommPy Algorithms](https://github.com/open-sdr/openofdm/tree/master/scripts/commpy): `scripts/commpy`

### Other components

- **USRP I/Q Source**
- **Decoded Bytes**
- **USRP Host**
- **Captured Samples**

## Connections

- USRP I/Q Source → dot11 PHY: streams I/Q
- dot11 PHY → Packet Sync: detects packets
- Packet Sync → Long Training: locates training
- Long Training → Frequency Correction: estimates offset
- Frequency Correction → OFDM FFT: corrects samples
- OFDM FFT → Channel Equalization: transforms symbols
- Channel Equalization → SIGNAL Decode: provides carriers
- SIGNAL Decode → Payload Decode: provides parameters
- Payload Decode → Decoded Bytes: outputs bytes
- dot11 PHY → USRP Host: returns packet bytes
- Captured Samples → Python Decoder: reads samples
- Python Decoder → CommPy Algorithms: uses algorithms
