URL
https://opencores.org/ocsvn/idea/idea/trunk
Subversion Repositories idea
[/] [idea/] [trunk/] [behavioral/] [key_regulator/] [fullsubstractor.vbe] - Rev 9
Compare with Previous | Blame | View Log
-- File Name : fullsubstractor.vbe
-- Description : Full Substractor in behavioral
-- Author : Mas Adit
-- Date : 29 Agustus 2001
ENTITY fullsubstractor IS
PORT(
a : IN BIT;
b : IN BIT;
bin : IN BIT;
diff : OUT BIT;
bout : OUT BIT;
vdd : in BIT;
vss : in BIT
);
END fullsubstractor;
ARCHITECTURE VBE OF fullsubstractor IS
BEGIN
ASSERT ((vdd and not (vss)) = '1')
REPORT "power supply is missing on fullsubstractor"
SEVERITY WARNING;
diff <= (a XOR b) XOR bin;
bout <= (bin AND NOT (a XOR b)) OR (NOT (a) AND b);
END VBE;