library IEEE; use IEEE.std_logic_1164.all; entity Vdlatch is port (D, C: in STD_LOGIC; Q, QN: buffer STD_LOGIC ); end Vdlatch; architecture Vdlatch_s of Vdlatch is signal DN, SN, RN: STD_LOGIC; component inv port (I: in STD_LOGIC; O: out STD_LOGIC ); end component; component nand2b port (I0, I1: in STD_LOGIC; O: buffer STD_LOGIC ); end component; begin U1: inv port map (D,DN); U2: nand2b port map (D,C,SN); U3: nand2b port map (C,DN,RN); U4: nand2b port map (SN,QN,Q); U5: nand2b port map (Q,RN,QN); end Vdlatch_s;