Nysa gives FPGA designs a self-describing ROM and a Python interface

FPGA, Python, Verilog

This is the read-only HTML version. For the full Visual Space experience, open the app.

FPGA development boards — Imag

FPGA development boards — Imag

Source: Nysa: FPGA Development Environment on Hackaday.io · Dave

FPGA development

Adding an FPGA core also means keeping host software in sync with its address and behavior. Nysa generates that description alongside the hardware image. Its 2015 storage experiments show another useful separation: Python controls the test while DMA moves data between DDR3 and a SATA drive.

🔥 1

An FPGA project can demand plenty of infrastructure before the interesting part starts: a bus, a way to communicate with a computer, and software that knows where each hardware block lives. Dave’s Nysa project on Hackaday.io tackles that setup work by assembling cores into an FPGA image and giving the host a Python interface. Its defining detail is a small ROM generated with the design, describing which cores are present and where to find them.

The project page was created on January 1, 2015, and the supplied development logs run through August 2 that year. These are historical experiments, not a newly launched toolchain, but the problem they address remains easy to recognize: changing hardware shouldn’t leave its controlling software guessing.

The FPGA carries its own description

Dave traces Nysa’s origins to connecting a Digilent Nexys 2 board to an LCD. The display worked; the amount of setup bothered him. He wanted adding a device to feel closer to reusing and adapting code in the Arduino ecosystem, rather than rebuilding the supporting machinery each time.

Nysa divides that work into three parts:

•
Core Builder generates Verilog project scaffolding, including tools for verification with Icarus Verilog and waveform viewing with GTKWave.
•
Image Builder combines cores with platform information and generates both the FPGA image and its descriptive ROM.
•
The host API provides Python read and write operations, plus helper functions, to communicate with the resulting design.

Dave describes graphically assembling existing cores without writing HDL. That’s a claim about composition, not about eliminating hardware design: a new custom core still needs its own logic and testing.

The ROM addresses a less visible source of trouble. In the May 31 self-describing-bus log, Dave explains how adding GPIO to an FPGA also requires the controller to know its location and characteristics. Maintaining that agreement through a separate document leaves room for missed changes. Generating the description alongside the image ties the host’s map to the hardware being built. It doesn’t prove a core works correctly, but it reduces the need to maintain that map twice.

A slow host link shapes the storage test

The most revealing example is the August 2 SATA and DDR3 update. Dave reported successful hard-drive reads and writes, then encountered a testing bottleneck: his computer-to-FPGA connection topped out around 16 MB/s, while he described the drive as reading and writing around 250 MB/s. Feeding every transfer from Python couldn’t stress the storage path at its intended rate.

He first put a temporary pattern generator and validator inside the SATA core. It wrote a pattern to disk, read it back and checked the result; Dave reported that this worked after debugging.

The next test brought SATA, DDR3 and DMA cores together in one Nysa image. The host would slowly load a 128 MB pattern into DDR3, then direct the DMA controller to move it to the drive. Before reading it back, the host cleared DDR3 so leftover data couldn’t masquerade as a successful disk read. Finally, it retrieved the memory contents for comparison.

That clearing step matters as much as the larger architecture: a readback test needs to distinguish newly returned data from data that was already there. The excerpt describes the procedure, but doesn’t provide a usable complete result transcript or establish sustained throughput.

Reusable infrastructure still consumes hardware

Nysa’s abstraction wasn’t free. In the January 1 log, an attempted NES design exceeded the smaller Dionysus board’s logic capacity, prompting work on the larger Artemis board. By May 28, Dave reported working DDR3 hardware and HDL, along with a DMA controller offering four input and four output ports through a FIFO-like interface.

That interface choice fits the project’s larger goal: custom cores could hand data to the DMA controller instead of each needing a bespoke memory connection. The Nysa repository is the supplied starting point for exploring the software; these excerpts don’t establish its current compatibility or maintenance status.

The useful lesson is the separation of responsibilities. Let generated metadata tell the host what hardware exists, let Python coordinate experiments, and let FPGA-side logic move the bulk data. For a design built this way, the next question is not just whether every core works alone, but whether their shared data path can keep up—and whether the test can reliably catch it when it doesn’t.

Source: Nysa: FPGA Development Environment

Hardware

3 Followers

A workshop for electronics and physical computing. Share circuits, boards, tools and prototypes; work through measurement and debugging, compare components, and document the choices that turn an idea into working hardware.

Visual Space is built for projects like this—where creators collaborate, organize goals, and grow communities around real work.