fpga
VhdlTutorials - Learn VHDL
A Guide To VHDL Language Constructs and Syntax

What is VHDL?

VHDL is a hardware descriptive language created by the government in the 1980s. It stands for VHSIC Hardware Descriptive Language, where VHSIC (Very High Speed Integrated Circuit) was a government program. The purpose of VHDL is to program an FPGA.

What is an FPGA?

The acronym FPGA stands for Field Programmable Gate Array. FPGAs are composed of thousands of programmable logic gates that signals travel through. Because an FPGA is a large array of logic circuitry, signals are processed and propogate in parallel, typically on a rising clock edge. This distinguishes them from other embedded systems such as microcontrollers which execute code in series. Because FPGAs process signals in parallel, they're extremely fast and excellent for processing large amounts of data. And because gates are reprogrammable, they also also very flexible devices.

VHDL isn't like software code that is executed line by line. Instead, it programs specific logic gates and flip flops into the FPGA, i.e. it describes the hardware. Once the FPGA has been programmed, signals simply pass through the programmed logic gates - code is not executed. Once VHDL code is written, it is built into bitstream file, which is then flashed on the FPGA. When you reprogram an FPGA you're redesigning the hardware, which can be very powerful compared to a software reprogram. When writing VHDL, it is important to understand digital logic and circuitry to write efficient and functional code.

Recommended Software

To write and test VHDL, you'll need an editor and a simulator. When you want to program the FPGA, you'll need different software to build the VHDL depending on the vendor of the FPGA you wish to program.

For an editor, I recommend two free applications. Visual Studio Code is a great editor for VHDL if you also install an extension from the Marketplace (also free). There are a few different extensions you can use for VHDL. I use the "VHDL" extension by "Pu Zhao"; however, there are other options if you want to explore. If you're unable to install Visual Studio Code or connect to the Marketplace, Notepad++ is also an acceptable editor. Notepad++ comes with VHDL syntax highlighting automatically.

For a simulator, I recommend Vivado or ModelSim. These simulators will compile your VHDL and run your test bench. When the test bench is simulated, a terminal will output the results and a waveform will be generated. From the waveform, you'll be able to see the state of signals and ports at every point in the simulation. Vivado is available for free and has a modern, efficient simulator. ModelSim is available to students for free as well, but has limited support. While Vivado has a nicer UI, it is less developed, and I've found ModelSim has better error reporting and more complex features.

And lastly, you will need to decide which FPGA you are going to synthesize your code into. Some of the most prominent brands include Xilinx, Intel, and Microsemi. Xilinx is most commonly used among beginners due to their wide range of FPGAs that are available. Vivado, their associated software is up-to-date, easy-to-use, and has the added bonus of tying all of the design tools into one app. Intel sells high-quality FPGAs that are often very expensive, making them unideal for a beginner. Microsemi tends to offer older, more reliable technologies, but their builds tools are more difficult to use.

To get started, Lesson 1 will go over VHDL entities.


Start Here:
Lesson 1

Lesson 2

Lesson 3