What is a D-latch? Write the VHDL Code for it?

Answer Posted / sghsg

library ieee;
use ieee.std_logic_1164.all;

entity D_latch is
port (
clk : in std_logic;
d : in std_logic;
q : out std_logic
);
end D_latch;

architecture arch_D_latch of D_latch is
begin
process(d,clk)
begin
-- +ve level sensitive
if(clk = '1') then
q <= d;
else
q <= q;
end if;
end process;
end arch_D_latch;

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What types of CMOS memories have you designed? What were their size? Speed?

2634


What is the difference between synchronous and asynchronous reset?

625


Mention what are the different gates where Boolean logic are applicable?

676


You have a driver that drives a long signal & connects to an input device. At the input device there is either overshoot, undershoot or signal threshold violations, what can be done to correct this problem?

2191


Describe a finite state machine that will detect three consecutive coin tosses (of one coin) that results in heads.

2321






what is verilog?

640


What is the difference between the mealy and moore state machine?

599


what is Slack?

711


Working of a 2-stage OPAMP?

2618


What is Body Effect?

2043


Are you familiar with the term snooping?

2927


For CMOS logic, give the various techniques you know to minimize power consumption

869


Explain the Various steps in Synthesis?

2837


How about voltage source?

1839


What is the ideal input and output resistance of a current source?

2524