VHDL is a language for expressing electrical hardware designs at various levels, ranging from low level descriptions of component interconnections to high level abstract representations of behavior. VHDL is widely used in industry and is an IEEE Standard. It is a powerful and flexibile language, and in this course we focus on a subset sufficient for basic combinational and sequential digital circuit design.
There are three basic techniques used in VHDL coding, and a VHDL design file can include one or more of these techniques:
To get a quick feel for VHDL, consider the digital circuit of Figure 47.
This circuit represents the Boolean function
In VHDL, this circuit can be represented by a signal assignment statement
X <= (A and B) or CThe symbol <= is the assignment operator. VHDL code for digital systems may consist of a set of statements within an architecture declaration, together with a specification of external interfaces via ports, listing signals that are to be inputs or outputs, in an entity declaration. As we shall see, VHDL is capable of specifying digital circuits at many levels of abstraction; the VHDL code above is behavioral or dataflow. A complete VHDL file for this circuit is as follows:
library IEEE; use IEEE.std_logic_1164.all; entity comb_cct is port ( A: in STD_LOGIC; B: in STD_LOGIC; C: in STD_LOGIC; X: out STD_LOGIC ); end comb_cct; architecture comb_cct_arch of comb_cct is begin X <= (A and B) or C; end comb_cct_arch;
In this VHDL file, note:
ANU Engineering - ENGN3213