Posted on Thursday, January 28, 2010 at 8:42 PM
4.2:Data Types:-
Data type is an attribute which specify which type of data an object can hold. Data types which are frequently used in VHDL will be discussed here.
4.2.1 STD_LOGIC:-
STD_LOGIC holds any one of the following values
'0', -- force 0
'1', -- force 1
'w', -- weak unknown
'u', -- uninitialized
'z', -- impedance
'h', -- weak 1
'l', -- weak 0
'x' and -- force unknown
'-' -- don't care.
Example 4.1:- SIGNAL a : STD_LOGIC;
a <= '0';
Example 4.2:- VARIABLE a : STD_LOGIC;
a := '1';
4.2.2 STD_LOGIC_VECTOR:-
STD_LOGIC_VECTOR holds an one dimensional array values as same as std_logic
Example 4.3:- SIGNAL a : STD_LOGIC_VECTOR(3 DOWNTO 0) := "0001";
-- Here ":=" is used to initialize the signal value this is recommended only in test bench not for writing RTL code...
Posted on Tuesday, November 24, 2009 at 4:14 AM