Abdellatif AliAutomatisierung · Embedded · SoftwareAutomation · Embedded · Software
ProjekteProjects/DigitaltechnikDigital design

FSM-Design auf FPGA mit VHDLFSM design on FPGA with VHDL

Digitale Logik und endliche Automaten in VHDL beschrieben, in der Simulation verifiziert und mit Intel Quartus auf echter FPGA-Hardware umgesetzt – der vollständige Entwurfsablauf von der Zustandsbeschreibung bis zur Hardware.Digital logic and finite state machines described in VHDL, verified in simulation and implemented on real FPGA hardware with Intel Quartus – the complete flow from state description to hardware.

RolleRoleBearbeitung der LaboraufgabenLab assignments
KontextContextDigitaltechnik, Hochschule HannoverDigital design, Hochschule Hannover
StackVHDL · Intel Quartus · FPGA
StatusAbgeschlossen · 2025Completed · 2025
01ÜberblickOverview

Verhalten präzise beschreiben – und in Hardware gießenDescribe behaviour precisely – and cast it in hardware

Endliche Automaten (FSM) sind das Rückgrat jeder Steuerlogik – von der Ampel bis zum Kommunikationsprotokoll. In diesem Laborprojekt habe ich digitale Logik und Automaten in VHDL beschrieben, ihr Verhalten in der Simulation überprüft und die Designs mit Intel Quartus synthetisiert und auf einem FPGA-Entwicklungsboard ausgeführt.Finite state machines (FSMs) are the backbone of every control logic – from traffic lights to communication protocols. In this lab project I described digital logic and state machines in VHDL, verified their behaviour in simulation, and synthesised and ran the designs on an FPGA development board with Intel Quartus.

02ZieleObjectives

Was erreicht werden sollteWhat it set out to achieve

  • Den kompletten digitalen Entwurfsablauf durchlaufen: Spezifikation → VHDL → Simulation → Synthese → Hardware.Work through the complete digital design flow: specification → VHDL → simulation → synthesis → hardware.
  • Zustandsautomaten sauber modellieren (Moore/Mealy, Zustandskodierung).Model state machines cleanly (Moore/Mealy, state encoding).
  • Verhalten vor der Hardware in der Simulation absichern.Secure the behaviour in simulation before moving to hardware.
03TechnikTechnology

Werkzeuge und KonzepteTools and concepts

VHDLIntel QuartusFPGAFunktionale SimulationFunctional simulation
  • Endliche Automaten (Moore / Mealy) und ZustandskodierungFinite state machines (Moore / Mealy) and state encoding
  • Kombinatorische und sequenzielle Logik, taktsynchrones DesignCombinational and sequential logic, synchronous design
  • Synthese und Implementierung auf dem FPGASynthesis and implementation on the FPGA
04VorgehenApproach

Vom Konzept zur UmsetzungFrom concept to implementation

  1. Gewünschtes Verhalten als Zustandsdiagramm spezifizieren.Specify the desired behaviour as a state diagram.
  2. Den Automaten in VHDL beschreiben.Describe the machine in VHDL.
  3. Zustandsübergänge in der funktionalen Simulation prüfen.Check state transitions in functional simulation.
  4. Mit Intel Quartus synthetisieren und auf dem FPGA ausführen.Synthesise with Intel Quartus and run on the FPGA.
05DemoDemo

Ein Automat zum DurchtaktenA state machine to clock through

Ein Moore-Automat erkennt die Bitfolge 1-0-1 (mit Überlappung). Wählen Sie das Eingangsbit, geben Sie Taktflanken – der Zustandswechsel erfolgt wie im FPGA nur mit dem Takt.A Moore machine detects the bit sequence 1-0-1 (overlapping). Choose the input bit and apply clock edges – as on the FPGA, the state only changes on the clock.

ZustandState: S0Illustration · nicht der LaborcodeIllustration · not the lab code
10101010 S0y=0 S1y=0 S2y=0 S3y=1

EingangsfolgeInput history: –

AusgangOutput y = 0

Typische VHDL-Struktur (Beispiel)Typical VHDL structure (example)
type state_t is (S0, S1, S2, S3);
signal state : state_t := S0;
process(clk) begin
  if rising_edge(clk) then
    if rst = '1' then state <= S0;
    else case state is
      when S0 => if x = '1' then state <= S1; end if;
      -- …
    end case; end if;
  end if;
end process;
y <= '1' when state = S3 else '0';
06Meine RolleMy role

Eigene Arbeit und RahmenMy work and the setting

Meine BearbeitungMy work

  • VHDL-Beschreibung der Schaltungen und AutomatenVHDL description of the circuits and state machines
  • Simulation und Synthese in Intel QuartusSimulation and synthesis in Intel Quartus
  • Test auf dem FPGA-BoardTesting on the FPGA board

BereitgestelltProvided

  • Aufgabenstellung des ModulsModule assignment
  • FPGA-Entwicklungsboard und LaborumgebungFPGA development board and lab environment
07HerausforderungenChallenges

Worauf es ankamWhat mattered

  • Korrekte Zustandskodierung und saubere Übergänge an den Taktflanken.Correct state encoding and clean transitions at the clock edges.
  • Verstehen, warum sich simuliertes Verhalten und synthetisierte Hardware unterscheiden können.Understanding why simulated behaviour and synthesised hardware can differ.
08TestTesting

Wie geprüft wurdeHow it was verified

Die Zustandsübergänge wurden zunächst in der funktionalen Simulation geprüft und anschließend auf dem FPGA-Board durch Betätigen der Eingänge und Beobachten der Ausgänge kontrolliert.State transitions were first checked in functional simulation and then verified on the FPGA board by operating the inputs and observing the outputs.

09Ergebnis & GrenzenResults & limits

Was vorliegt – und was nichtWhat exists – and what does not

Die Automaten liefen nach Simulation und Synthese auf der FPGA-Hardware. Das Projekt vermittelte den vollständigen Entwurfsablauf, auf dem auch komplexere Steuerungen aufbauen.After simulation and synthesis, the state machines ran on the FPGA hardware. The project covered the complete design flow on which more complex controllers build.

Die Original-Quelldateien sind derzeit nicht veröffentlicht; das GitHub-Repository enthält die Projektdokumentation. Konkrete Messwerte oder Screenshots der Laborergebnisse liegen in den verfügbaren Unterlagen nicht vor und werden deshalb hier nicht gezeigt.The original source files are not published yet; the GitHub repository holds the project documentation. Specific measurements or screenshots of the lab results are not part of the available material and are therefore not shown here.

10DokumentationDocumentation

QuellenSources