Close

WPMS Synthesizer — Layer 1 Specification [ 1 ]

A project log for FPGA Spectrum Engine

10,240 independent oscillators · 1-sample latency · 0.001 Hz resolution

tsuneoohnakaTsuneo.Ohnaka 05/03/2026 at 11:310 Comments

Chapter 1: Scope and Boundary Conditions [Part 1 of 2]

WPMS シンセサイザー — 第1層仕様書

第1章:スコープと境界条件

License: CC0 1.0 Universal (Public Domain) This is the architectural specification for a Wave Packet Modulation Synthesis (WPMS) synthesizer implementing the FPGA physical layer of the FPGA Spectrum Engine in standalone form. Read it, redistribute it, build on it, regenerate from it.
ライセンス:CC0 1.0 Universal(パブリックドメイン) これは波束変調合成 (WPMS) シンセサイザーのアーキテクチャ仕様書であり、FPGA Spectrum Engine の FPGA 物理層を単独形態で実装するものである。読み、再配布し、その上に構築し、再生成してよい。

1.1 Purpose of this Synthesizer / 本シンセサイザーの目的

The WPMS Synthesizer is a standalone FPGA implementation that produces audible output from a single FPGA device, using only the physical layer of the FPGA Spectrum Engine three-layer architecture (FPGA physical layer / ARM intermediate layer / PC abstraction layer). Neither the ARM intermediate layer (running on the Cyclone V SoC's HPS) nor the PC abstraction layer (Max/MSP, OSC servers, Ableton Live integration) is present or required.

WPMS シンセサイザーは、FPGA Spectrum Engine の3層アーキテクチャ(FPGA 物理層/ARM 中間層/PC 抽象層)のうち、物理層のみを用いて、単一の FPGA デバイスから可聴出力を得る単独実装である。ARM 中間層(Cyclone V SoC の HPS 上で動作する)も、PC 抽象層(Max/MSP、OSC サーバ、Ableton Live 連携)も存在せず、要求されない。

Three concrete intentions drive this scope:

このスコープは三つの具体的な意図によって駆動されている:

Intention 1 — Earliest possible audible output. The WPMS Synthesizer is the first deliverable in the FPGA Spectrum Engine roadmap because it is the shortest path from "repository contents" to "sound coming out of a speaker." Readers of the Hackaday.io project should be able to write the provided .rbf to a DE10-nano, connect HDMI to a monitor, and hear sound — without any additional software, build environment, or ARM-side configuration.

意図1 — 可能な限り早期の可聴出力。 WPMS シンセサイザーは FPGA Spectrum Engine ロードマップにおける最初の成果物である。「リポジトリの内容」から「スピーカーから音が出る」までの最短経路だからである。Hackaday.io プロジェクトの読者は、提供される .rbf を DE10-nano に書き込み、HDMI をモニタに接続し、追加のソフトウェア、ビルド環境、ARM 側構成なしに音を聴けるようにすべきである。

Intention 2 — Reusable component foundation. Although the physical-layer-only architecture will be partially superseded when the ARM intermediate layer is introduced, the components built for the WPMS Synthesizer — the Maclaurin polynomial pipeline, the sequence-modulation pipeline processor, the HDMI audio output path, the AXI-abstracted input switch — are the same components that the full FPGA Spectrum Engine will use as its physical layer core. Nothing built here is throwaway; everything is foundational.

意図2 — 再利用可能な部品の基盤。 物理層単独アーキテクチャは ARM 中間層導入時に部分的に置き換えられるが、WPMS シンセサイザー用に構築される部品——マクローリン多項式パイプライン、数列変調パイプラインプロセッサ、HDMI オーディオ出力経路、AXI 抽象化入力スイッチ——は、完全な FPGA Spectrum Engine がその物理層の中核として用いる、まさに同じ部品である。ここで作られるものに使い捨ては一つもない。すべてが基礎的である。

Intention 3 — Validation of the Open Prompt regeneration loop. The WPMS Synthesizer is structurally simple enough that its Layer 1 specification, Layer 2 reasoning traces, and a sample Layer 3 implementation can be produced and verified at modest scale. This makes it the first real test of the Open Prompt premise: can an independent engineer, given Layers 1 and 2 plus an LLM collaborator, regenerate a working implementation? If the WPMS Synthesizer can be regenerated independently, the methodology is validated for the larger, more complex Spectrum Engine that follows.

意図3 — Open Prompt 再生成ループの検証。 WPMS シンセサイザーは構造的に十分単純であり、その第1層仕様、第2層推論軌跡、第3層サンプル実装を、控えめな規模で生産し検証できる。これは Open Prompt の前提に対する最初の実証となる:独立したエンジニアが第1層と第2層に LLM 協働者を加えて、動作する実装を再生成できるか。WPMS シンセサイザーが独立に再生成できるなら、方法論はその後に続くより大きく複雑な Spectrum Engine に対して妥当性が示されることになる。

1.2 Target Platform / 対象プラットフォーム

Hardware: Terasic DE10-nano (Cyclone V SoC, 5CSEBA6U23I7).

ハードウェア: Terasic DE10-nano(Cyclone V SoC、5CSEBA6U23I7)。

FPGA fabric usage: This specification uses only the FPGA fabric portion of the Cyclone V SoC. The HPS (ARM Cortex-A9 dual-core) is not used in this specification. No Linux, no bootloader, no HPS firmware is required to run the WPMS Synthesizer. The .rbf file alone, written via Quartus Programmer or via the SD-card boot path with HPS held in reset, is sufficient.

FPGA ファブリックの利用: 本仕様は Cyclone V SoC の FPGA ファブリック部分のみを使用する。HPS(ARM Cortex-A9 デュアルコア)は本仕様では使用しない。WPMS シンセサイザーの動作に Linux、ブートローダ、HPS ファームウェアは要求されない。Quartus Programmer 経由で書き込まれた .rbf ファイル単独、または HPS をリセット保持したまま SD カードブート経路で書き込まれた .rbf で十分である。

Why DE10-nano specifically:

なぜ DE10-nano なのか:

Substitution policy: Other Cyclone V SoC boards (e.g., the Terasic C5G that hosts the original prototype) are acceptable substitutes provided their DSP block count, BRAM capacity, and HDMI output capability are equal to or greater than the DE10-nano's. Migration to larger Intel/Altera FPGAs (e.g., DE25-nano, Agilex-based boards) is anticipated but is outside the scope of this Layer 1 document.

代替方針: 他の Cyclone V SoC ボード(オリジナルプロトタイプをホストした Terasic C5G など)は、DSP ブロック数、BRAM 容量、HDMI 出力能力が DE10-nano と同等以上であれば代替可能である。より大きな Intel/Altera FPGA(DE25-nano、Agilex 系ボードなど)への移行は予期されているが、本第1層文書の範囲外である。

1.3 Audio Output / オーディオ出力

Output path: HDMI audio, embedded in the HDMI signal driven from the DE10-nano's HDMI transmitter. The audio is decoded by an external DAC inside the HDMI monitor, computer display, or HDMI audio extractor connected to the board's HDMI output. No analog audio output is provided by the DE10-nano itself, and adding one is not in scope.

出力経路: DE10-nano の HDMI 送信器から駆動される HDMI 信号に埋め込まれた HDMI オーディオ。オーディオはボードの HDMI 出力に接続された HDMI モニタ、コンピュータディスプレイ、または HDMI オーディオエクストラクタ内部の外部 DAC によりデコードされる。DE10-nano 自体はアナログオーディオ出力を提供しない、そしてその追加は本スコープ外である。

Sample rate: 48 kHz (one sample period = 20.833 µs).

サンプルレート: 48 kHz(1 サンプル期間 = 20.833 µs)。

Sample format: 24-bit signed PCM, two channels (L/R, content identical in monaural baseline).

サンプル形式: 24-bit 符号付き PCM、2 チャンネル(L/R、モノラル基準では内容同一)。

HDMI audio core selection: The HDMI audio path uses an open-source MiSTer-ecosystem HDMI core as its starting point. The exact core is left as an Implementation Arena choice, with the selection rationale and integration details to be recorded in the Layer 2 trace produced during implementation.

HDMI オーディオコアの選定: HDMI オーディオ経路はオープンソースの MiSTer エコシステム HDMI コアを起点とする。正確なコア選定は Implementation Arena の選択として残し、選定根拠と統合詳細は実装中に作成される第2層軌跡に記録する。

Why HDMI rather than dedicated I²S DAC:

なぜ専用 I²S DAC ではなく HDMI なのか:

1.4 Synthesis Method / 合成方式

Method: Wave Packet Modulation Synthesis (WPMS) only. Sideband fractal synthesis, additive synthesis with arbitrary per-bin parameters, and SDFT analysis are outside the scope of this Layer 1 document and are deferred to subsequent specifications.

方式: 波束変調合成 (WPMS) のみ。サイドバンドフラクタル合成、任意のビン別パラメータを持つ加算合成、SDFT 分析は本第1層文書の範囲外であり、後続の仕様に延期される。

Mathematical formulation: Each bin k ∈ {0, 1, ..., N−1} contributes a sinusoidal component whose frequency, amplitude, and phase are closed-form functions of k and a small set of scalar parameters:

数学的定式化: 各ビン k ∈ {0, 1, ..., N−1} は、その周波数、振幅、位相が k と少数のスカラーパラメータの閉形式関数となる正弦波成分を寄与する:

f_k = f₀ + k · Δf + α · k²
A_k = A₀ · exp(−β · k) · exp(−γ · (k − N/2)²)
φ_k = φ₀ + k · δφ + ψ · k²

Free parameters:

自由パラメータ:

SymbolMeaningRole
f₀Fundamental (lowest bin) frequencyCenter of the wave packet
ΔfLinear frequency spacingBin density
αQuadratic frequency spreadInharmonicity / chirp
A₀Peak amplitudeOverall level
βExponential amplitude decaySpectral tilt
γGaussian amplitude weightingWave-packet smoothness
φ₀Phase at k = 0Global phase offset
δφLinear phase gradientGroup delay (time shift)
ψQuadratic phase coefficientLinear chirp / pulse compression
NNumber of active binsWave packet sharpness / count

Total: nine scalar parameters plus one count parameter.

合計:9 個のスカラーパラメータと 1 個の数量パラメータ。

Phenomenological span of the parameter space:

パラメータ空間の現象学的広がり:

Why WPMS rather than full additive:

なぜフル加算合成ではなく WPMS なのか:

1.5 Bin Count and Module Configuration / ビン数とモジュール構成

Decision: Tie — multiple module configurations are kept in the Implementation Arena.

決定:引き分け — 複数のモジュール構成を Implementation Arena に保持する。

The Layer 1 specification recognizes three logically equivalent module configurations:

第1層仕様は、3 つの論理的に等価なモジュール構成を認める:

ConfigurationModulesBinsTarget Platform
Compact2 modules × 2,048 bins4,096DE10-nano (this document's reference)
Standard5 modules × 2,048 bins10,240C5G-equivalent on DE10-nano (subject to timing)
Extended10 modules × 2,048 bins20,480DE25-nano or larger (anticipated, out of scope here)

Logical equivalence: At the source-level architecture, the three configurations differ only in the value of a single generate parameter that instantiates the module count. The Maclaurin pipeline, the sequence-modulation pipeline processor, the per-module bin allocation, and the summation tree structure are all parameterized to accept any value M ∈ {2, 5, 10, ...} at compile time.

論理的等価性: ソースレベルアーキテクチャにおいて、3 つの構成はモジュール数をインスタンス化する単一の generate パラメータの値においてのみ異なる。マクローリンパイプライン、数列変調パイプラインプロセッサ、モジュールごとのビン配分、総和ツリー構造はすべてパラメータ化されており、コンパイル時に任意の値 M ∈ {2, 5, 10, ...} を受け入れる。

Implementation reality is not the same as logical equivalence. As module count rises, implementation-level pressures emerge non-linearly:

実装現実は論理的等価性と同じではない。 モジュール数が上昇するにつれ、実装レベルの圧力が非線形に立ち現れる:

Each module-count threshold is a real engineering frontier. Crossing it typically requires implementation-level work — pipeline retiming, register replication, manual placement constraints, sometimes architectural refinements that raise the achievable Fmax. Such Fmax improvements can in turn unlock the next module-count tier, creating a recursive expansion path that is not predictable from the logical specification alone.

各モジュール数の閾値は本物の工学的前線である。 これを越えるには通常、実装レベルの作業——パイプラインリタイミング、レジスタ複製、手動配置制約、時にはアーキテクチャの洗練によって達成可能 Fmax を引き上げること——が要求される。そのような Fmax の改善は、今度は次のモジュール数階層を解錠し得る——論理仕様単独では予測不能な再帰的拡張経路を作り出す。

This phenomenon is one of the strongest reasons for the existence of Open Prompt as a methodology. The reasoning behind a specific Fmax breakthrough — what was tried, what failed, what timing reports said, what the decisive trade-off was — is precisely the kind of knowledge that does not survive in source code alone. It must be preserved as Layer 2 reasoning traces. A future implementer porting to DE25-nano three years from now should be able to load these traces into their LLM collaborator and recover not just the code but the judgment behind the code.

この現象は、方法論としての Open Prompt の存在理由の最も強いものの一つである。 特定の Fmax 突破の背後にある推論——何を試み、何が失敗し、タイミングレポートが何を言い、決定的なトレードオフが何だったか——は、まさにソースコード単独では生き残らない種類の知識である。それは第2層推論軌跡として保存されねばならない。3 年後に DE25-nano に移植する将来の実装者は、これらの軌跡を LLM 協働者にロードし、コードだけでなくコードの背後にある判断を回復できるべきである。

Reference implementation choice for Layer 3:

第3層リファレンス実装の選択:

The first reference implementation provided in Layer 3 will use the Compact configuration (2 modules, 4,096 bins). This is selected as the starting point for three reasons:

第3層で提供される最初のリファレンス実装は Compact 構成(2 モジュール、4,096 ビン) を用いる。これは 3 つの理由により出発点として選定される:

  1. Compact has the highest probability of timing closure on DE10-nano on first attempt, ensuring the inaugural release works for all readers. / Compact は初回試行で DE10-nano 上でのタイミング収束確率が最も高く、最初のリリースがすべての読者で動作することを保証する。
  2. Compact has comfortable DSP budget, allowing the 11th-order Maclaurin polynomial and 24-bit amplitude width to be retained. / Compact は快適な DSP 予算を持ち、11 次マクローリン多項式と 24 ビット振幅幅の維持を可能にする。
  3. The progression Compact → Standard → Extended provides clear motivating boundaries for future Layer 2 reasoning traces, each documenting an Fmax-threshold breakthrough. / Compact → Standard → Extended の進展は、それぞれ Fmax 閾値突破を文書化する将来の第2層推論軌跡に対する、明確な動機付けの境界を提供する。

The Standard and Extended configurations are explicitly invited as community contributions. The bin-count choice itself is therefore a Tie Decision in the Implementation Arena, with the Compact starting point being a first-implementation convention rather than an architectural commitment.

Standard と Extended の構成はコミュニティ貢献として明示的に招待される。したがってビン数の選択そのものが Implementation Arena における引き分け判断であり、Compact 出発点はアーキテクチャ的コミットメントではなく最初の実装の慣行である。

1.6 Maclaurin Pipeline Configuration / マクローリンパイプライン構成

Polynomial degree: 11th-order Maclaurin expansion of sin(x), retained from the C5G prototype.

多項式次数: sin(x) の 11 次マクローリン展開、C5G プロトタイプから継承。

Internal bit widths (Compact-configuration reference):

内部ビット幅(Compact 構成基準):

StageWidthFormat
Trigonometric core40 bitssigned fixed-point
Amplitude (level) multiplier24 bitsunsigned fixed-point (Compact configuration retains C5G-era width)
Per-module summation accumulator64 bitssigned fixed-point
Output to HDMI audio path24 bitssigned PCM
Final decimal-point selector6-bit shiftDIP-switch-controlled (3 DIP positions × 2 bits resolution)

The 11th-order / 24-bit retention is permitted by the Compact configuration's reduced module count: with only 2 modules instead of 5, DSP-block budget is comfortable on DE10-nano (2 modules × ~20 DSP ≈ 40 DSP for the iDFT/WPMS pipelines, with ~47 DSP remaining for the sequence-modulation processor, the HDMI core, and other subsystems).

11 次/24 ビットの維持は、Compact 構成の縮小されたモジュール数により許容される:5 モジュールではなく 2 モジュールのみで、DSP ブロック予算は DE10-nano 上で快適である(2 モジュール × 約 20 DSP ≈ 40 DSP が iDFT/WPMS パイプライン用、約 47 DSP が数列変調プロセッサ、HDMI コア、その他のサブシステム用に残る)。

For Standard and Extended configurations, polynomial degree and amplitude bit-width may be reduced (e.g., 7th-order Maclaurin and 16-bit amplitude) as discussed in the 2026-04-18 reasoning trace decision-point DP-9. Such trade-offs are recorded as Implementation Arena variants when they are realized.

Standard と Extended の構成では、2026-04-18 推論軌跡の決定点 DP-9 で議論されたように、多項式次数と振幅ビット幅は削減され得る(7 次マクローリンと 16 ビット振幅など)。そのようなトレードオフは、それらが実現される時点で Implementation Arena の変種として記録される。

Detailed pipeline architecture: Deferred to Chapter 2 (Maclaurin Pipeline Specification), to be drafted in subsequent dialogue.

詳細パイプラインアーキテクチャ: 第 2 章(マクローリンパイプライン仕様)に委ね、後続の対話で起草される。

Discussions