Implement a 1011 Moore sequence detector in Verilog. In addition to detecting the sequence, the circuit keeps track of modulo-256 count of the 1011 sequences ever detected. When the correct sequence is detected, the w output becomes 1 and at the same time an 8-bit counter is incremented.
A. Show the state diagram for this circuit.
B. Describe the circuit in a synthesizable Verilog code. Use this for simulation by ModelSim.
C. Write a testbench for the circuit in Verilog that tests the correctness of your circuit.
Implement a 1011 Moore sequence detector in Verilog.
The Moore FSM keeps detecting a binary sequence from a digital input and the output of FSM which goes high only when a "1011" sequence is detected.
(A) The state diagram of the Moore FSM for a sequence detector is shown in figure below -
We know that, the Moore FSM output depends on the current state of the FSM.
(B) Describe the circuit in a synthesizable Verilog code. Use this for simulation by ModelSim.
(C) Write a testbench for the circuit in Verilog that tests the correctness of our circuit.
Verilog Testbench for sequence detector using Moore FSM which is given as -
module tb_Sequence_Detector_Moore_FSM_Verilog ;
// Inputs
reg sequence_in ;
reg clock ;
reg reset ;
// Outputs
wire detector_out ;
// Instantiate the Sequence Detector using Moore FSM
Sequence_Detector_Moore_FSM_Verilog uut
{
.sequence_in (sequence_in) ,
.clock (clock) ,
.reset (reset) ,
.detector_out (detector_out)
} ;
initial begin
clock = 0 ;
forever #5 clock clock ;
end
initial begin
// Initialize Inputs
sequence_in = 0 ;
reset = 1 ;
// wait 100 ns for global reset to finish
#30 ;
reset = 0 ;
#40 ;
sequence_in = 1 ;
#10 ;
sequence_in = 0 ;
#10 ;
sequence_in = 1 ;
#20 ;
sequence_in = 0 ;
#20 ;
sequence_in = 1 ;
#20 ;
sequence_in = 0 ;
// Add stimulus here
end
endmodule
Implement a 1011 Moore sequence detector in Verilog. In addition to detecting the sequence, the circuit...
Write a behavioral Verilog module for a 4-bit Johnson counter that has 8 states. The counter loads the "0000" state if reset is low. The counter should start and end with this state. Write a testbench to verify the correctness of the 4-bit Johnson counter. The testbenclh should have a clock with a period of 20ns and a reset signal. The testbench should store the 4-bit binary outputs of the counter in a file, which will be used to provide...
2. (20 points) Instead of using a Moore machine to implement the sequence detector in problem 1, derive a state diagram for a Mealy machine that will perform this operation. 1. (20 points) For this problem, we want to design a circuit that checks for the input sequence 00101. Your circuit will have a one-bit input W and a one-bit output Z where Z-1 if the last five values of W observed on each positive edge of the clock are...
9. Product State Graph ou are asked to design a sequence detector to detect the input codes 10 and 01. The input of the circuit is and the output is Z, which only changes at a clock edge. Overlaps must also be detected. Z only changes at the clock edge . [2%] A. Restate the problem by circling the most appropriate term within the parentheses 1. The circuilt type is (combinational- asynchronous- FSM). 2. The subcategory of the circuit is...