Behavioral Modeling


Behavioral modeling:

In this style of modeling, the internal working of an entity can be implemented using set of statements.

It contains:
• Process statements
• Sequential statements
• Signal assignment statements
• Wait statements

Process statement is the primary mechanism used to model the behavior of an entity. It contains sequential statements, variable assignment (:=) statements or signal assignment (<=) statements etc. It may or may not contain sensitivity list. If there is an event occurs on any of the signals in the sensitivity list, the statements within the process is executed. Inside the process the execution of statements will be sequential and if one entity is having two processes the execution of these processes will be concurrent. At the end it waits for another event to occur.

library IEEE;
use IEEE.STD_LOGIC_1164.all;

entity ha_beha_en is
port(
A : in BIT;
B : in BIT;
S : out BIT;
C : out BIT
);
end ha_beha_en;


architecture ha_beha_ar of ha_beha_en is
begin
process_beh:process(A,B)
begin
S<= A xor B;
C<=A and B;
end process process_beh;

end ha_beha_ar;

Here whenever there is a change in the value of a or b the process statements are executed.