Question HVL234
Question HVL234
6. Design a logic which mimics an infinite width register. It takes input serially 1 bit at a time. Output
is asserted high when this register holds a value which is divisible by 5. KEY: You can make such
ckt not only for 5 but for any number.
7. How can "X"s be used to debug state machines?
8. Where we can use one hot state machine?
9. Describe a finite state machine that will detect three consecutive coin tosses (of one coin) that
results in heads.
10. Design a Pattern matching State Machine. Output is asserted if pattern "101" is detected in last 4
inputs. How will you modify this design if it is required to detect same "101" pattern anywhere in
last 8 samples?
11. Design a finite state machine to behave like a modulo 3 counter when x = 0 and modulo 4 when
x=1.
12. What is a modulo operator? Why do we call a Modulo-N Counter?
13. Asynchronous FIFO Controller with full and empty flags.
14. Calculate a Sync FIFO depth for the following spec. Input data rate = 80 clocks
continuous data and 20 clocks idle. Output data rate = 8 clocks data and 2 clocks
idle. ANSWER is as Below
<-20-><-80->|<-80-><-20->
First burst | second burst
Here, effective writing is only for 160 clock cycles, So worst write is 160 words/160 clks.
15. Why do we need grey code for the dual clock FIFO design?
16. FIFO Depth Calculation: Write clock is 4 times faster than Read clock. There will
be only one write once in 4 write clocks, but can be any clock of 4 clocks. Where
as Read will happen every clock. What will be the minimum depth for the Full and
Empty condition wont be asserted.
17. simplify this : (A + B) (A + Bbar)
18. What’s the diff between a half and a full adder?
19. How to do the signed multiplication using an unsigned multiplier?
20. swap x and y.
x=x-y;
y=x+y;
x=y-x;
or
X = X ^ Y;
Y = Y ^ X;
X = X ^ Y;
35. Design a black box whose input clock and output relationship as shown in
diagram.
__ __ __ __ __ __ __ __ __
clk __| |__| |__| |__| |__| |__| |__| |__| |__| |__
__ __ __ __ __
Output __| |______| |______| |______| |______| |__
36. Design a digital circuit to delay the negative edge of the input
signal by 2 clock cycles.
__________
input ________| |_____________
_ _ _ _ _ _ _ _ _ _ _ _ _
clock _| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_| |_
______________
output _________| |___________
37. Design a 4:1 mux using 2:1 mux.
38. Design a 2 bit comparator with GT, EQ and LT.
39. Design a Toggle flop using a D type flop.
40. F = wx’y’ + yw’z’ + yxz + yxw. Implement this function using a mux.
41. Design a JK flop using a Toggle flop.
42. Give two ways of converting a two input NAND gate to an inverter.
43. How do you detect if two 8-bit signals are same?
44. What is a carry save adder?
45. How do you design a carry select adder?
46. Design a logic for 15B/8.
47. Design AND, OR, NAND, NOR, NOT, XOR, XNOR gates using 2:1 MUX.
48. Frequency Dividers (1/2, 1/3, 1/5 etc.)
49. Frequency Multiplier.
50. Setup Time Calculagtion Questions.
51. Hold Time Calculagtion Questions.
52. Counters, Modulo-N Counters
53. Adders, Half Adders, Carry Save Adders, Look Ahead Carry Generator.
54. Multipliers.
55. How to achieve AB'+BA', Using NAND gates only.
56. Generate clock using:
-- T FF
-- D FF
57. If there is a data-write-read mismatch in FIFO (DWRITE Vs DREAD), what can be the
cause?
58. FIFO Depth questions.
59. Coverage is 60%. How will you improve functional coverage.
- Directed testcases
- exclude option
- run more tests with different seeds
60. Why we avoid latches in the design:
Inferred Latches: Are result of incomplete if/case constructs etc. As such latches will
unnecessarily eat up Area… So to avoid this we try to avoid any code that would infer into
latches.
Latches in place of FFs: Can be used in asynchronous ckts.. that too with some extra logic to
suppress the glitch on enable. Smaller in size as compared to FFs(Master-Slave). We don’t have
Scanable Latches so not recommended for a design that require DFT support.
72. Referring to the diagram below, briefly explain what will happen if the propagation
delay of the clock signal in path B is much too high compared to path A. How do we
solve this problem if the propagation delay in path B can not be reduced ?
73. What is the function of a D flip-flop, whose inverted output is connected to its input ?
74. Design a circuit to divide input frequency by 2.
75. Design a divide-by-3 sequential circuit with 50 duty cycle.
76. Design a divide-by-5 sequential circuit with 50 duty cycle.
77. What are the different types of adder implementations ?
78. Draw a Transmission Gate-based D-Latch.
79. Give the truth table for a Half Adder. Give a gate level implementation of it.
80. What is the purpose of the buffer in the circuit below, is it necessary/redundant to have a
buffer ?
81. What is the output of the circuit below, assuming that value of 'X' is not known ?
82. Consider a circular disk as shown in the figure below with two sensors mounted X, Y and
a blue shade painted on the disk for an angle of 45 degree. Design a circuit with minimum
number of gates to detect the direction of rotation.
83. Design an OR gate from 2:1 MUX.
84. Design an XOR gate from 2:1 MUX and a NOT gate
90. Design a 4:1 Mux using 2:1 Muxes and some combo logic.
91. What is metastable state ? How does it occur ?
92. What is metastability ?
93. Design a 3:8 decoder
94. Design a FSM to detect sequence "101" in input sequence.
95. Convert NAND gate into Inverter, in two different ways.
96. Design a D and T flip flop using 2:1 mux; use of other components not allowed, just the
mux.
97. Design a divide by two counter using D-Latch.
98. Design D Latch from SR flip-flop.
99. Define Clock Skew , Negative Clock Skew, Positive Clock Skew.
100. What is Race Condition ?
101. Design a 4 bit Gray Counter.
102. Design 4-bit Synchronous counter, Asynchronous counter.
103. Design a 16 byte Asynchronous FIFO.
104. What is the difference between an EEPROM and a FLASH ?
105. What is the difference between a NAND-based Flash and a NOR-based Flash ?
106. You are given a 100 MHz clock. Design a 33.3 MHz clock with and without 50%
duty cycle.
107. Design a Read on Reset System ?
108. Which one is superior: Asynchronous Reset or Synchronous Reset ? Explain.
109. Design a State machine for Traffic Control at a Four point Junction.
110. What are FIFO's? Can you draw the block diagram of FIFO? Could you modify it to
make it asynchronous FIFO ?
111. How can you generate random sequences in digital circuits?
112. assign out = sel?in1:in2; // How out will respond to sel = X? // I think out should go X
113. always@(sel or in1 or in2)
if(sel)
out = in1;
else
out = in2;