Langage de programmation VHDL

Exploring the VHDL Programming Language

Introduction

VHDL is an extremely powerful, standardized language for describing and designing digital hardware systems of the very high-speed integrated circuits type (VHSIC). The US DoD first developed it in the 1980s before making it an IEEE standard (1076) the following year. In many industries, VHDL is an important tool, used to specify, simulate, and realize large-scale complex digital circuits and systems.

Usage

The VHDL language finds application in various areas, including:

Designing ASICs (Application-Specific Integrated Circuits):

It is used to write descriptions of, design, and simulate the customized integrated circuits called application-specific integrated circuits (ASICs), intended specifically to perform certain functions.

Programming Programmable Components:

This makes it a perfect language for programming devices such as CPLDs and FPGAs. Engineers use these components to design hardware logic specifically for certain purposes.

Creating Digital Simulation Models:

Digital simulation models are created using VHDL and verify whether the electric circuits can work on logical level before they are printed. This speeds up the development process, therefore, saving time and money.

Developing Test Benches:

Test benches that engineers utilize are virtual test environments where electronic components and systems can be examined for their proper functioning.

 VHDL is an important tool for electronic design engineers enabling them to describe, verify and fabricate diverse electronic equipment, comprising custom ASICs, PLDs and Digital simulators.

Structural Aspects of a Basic VHDL Description.

A VHDL description consists of two integral parts:

Entity (ENTITY):

This section identifies the inputs and outputs of the given digital circuit or system. The black box part of the design, so its the signals the component interacts with on a top level.

Architecture (ARCHITECTURE)

 In order for such a design to be completely characterized, there is always an accompanying architecture portion that contains instructions in the form of VHDL code defining what to do with the described digital system or component. This entails elements like logical operation, behaviors, functions, and how inputs turn into output during the processing of the design.

Broadly, Entity describes what goes in and what comes out; Architecture specifies how the component processes these inputs to yield the required results. The book is divided into two parts that provide an overall VHDL representation of a digital circuit or component.

Library Declarations in VHDL


When synthesizing descriptions, library declarations in VHDL prove essential. A set of predefined standard modules, functions, and procedures that may be used within any given VHDL design is referred to as a library. The famous libraries are those from the IEEE including such as the IEEE IEEE 1164 library.

Here’s a brief explanation:

  • Library Declarations: Usually at the beginning of a VHDL file one would declare the libraries used by this particular design. For example, if you intend to use elements from the IEEE 1164 library, you declare it like this:

Library ieee;
Use ieee.std_logic_1164.all;
Use ieee.numeric_std.all;
Use ieee.std_logic_unsigned.all;

  Here you say that in your declaration you are applying for the complete IEEE library, including all materials from the IEEE 1164 library. It enables you to utilize standard-logic types like STD_LOGIX that are widely used in digital designs.

  • Library Usage: After declaring a library, you may utilize its elements in your VHDL code. For instance, when declaring a signal, a port or variable in your design, you have used standard data types like STD_LOGIC. Additionally, you can employ various built-in logical operators and functions provided in the library as well.

     

By using standardized libraries such as IEEE 1164, consistency is maintained among various VHDL designs and tools. This enables easier development through common reusable elements for digital design.

Declaration of Entity in VHDL

The declaration of an entity in VHDL plays a key role in the designation of the name, inputs and outputs of the VHDOL description. The instruction that defines these inputs and outputs is “port.” Here is how it is typically done in terms of syntax:

entity ENTITY_NAME is
port (
— Description of input and/or output signals
);
end ENTITY_NAME;

ENTITY_NAME: This is the definition of the entity mentioned above. The given name should be unqiue in your VHDL project that has been mentioned earlier.
port: Port; this is a keyword telling you that you are about to tell what the input and/ or output signals this thing has.
Description of input/output signals : Here, you enter all of the input(s) and output(s) for the said entity. These signals are defined using the syntax previously discussed.

Here is an example of declaring an entity in VHDL:

entity MyEntity is
     port (
          A : in STD_LOGIC; — Input signal
         B : in STD_LOGIC; — Input signal
       Z : out STD_LOGIC — Output signal
          );
end MyEntity;

In this example, “MyEntity” is the name of the entity, and it has three signals: The circuit is composed of two inputs (A and B) and a single output (Z). Below each signal, there is its name, type which in our case is “STD_LOGIC” and direction which is “in” for inputs and “out” for outputs.
This involves issuing a declaration for the entity, which provides the signals associated with the VHDL description, i.e. those by means of which the entity will interact with the remainder of the systems.

In VHDL, after the last signal definition in the port statement, you should never put a semicolon.

The port statement syntax is: SIGNAL_NAME: direction type; – For each signal, you must define the SIGNAL_NAME, direction, and type.”

Leave a Comment

Your email address will not be published. Required fields are marked *