Week 5 HW
Noah Smith
1.
In Section 1, don't look at the logic
equations provided to you. From the state table, find the logic equations for
q1(n+1) and y and draw the sequential circuit for q1(n+1) and y. (10 points)
2. Repeat the work in Section 3. Use two methods, the given one and the
behavioral one. Show simulation results. (15 points)
Code
and results for the logic expression method.
Code and results for the behavioural method.
3.
Similar to the sequence detector in Section 3, change
the sequence to be detected to 1011, design the state diagram, draw the truth
table, find the logic equations, and design the verilog
module and testbench to verify the logic. (15 points)
Here
is the hand work for the sequence detector for 1011.
Code
for the sequence detector of 1011, I chose to use the behavioral method to do
this as it was easier to troubleshoot than the logic equations. This behavioral
method was built directly off the state diagram.
Simulation
results of the
sequence detector.
4. Simulate the four types of shift registers in Section 5. (20 points)
Serial in Serial out code and simulation.
Serial
in Parallel out code and simulation.
Parallel in serial out code and simulation
Parallel
in parallel out code and simulation.
5. Build a counter module and
show the simulation results. (20 points)
I
chose to implement the up down 4 bit counter with reset
functions. Code and simulation below
6. Find the logic equation of
the following circuit and implement it in verilog. Show the
simulation results. (20 points)