Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Figure 6 shows a 7-segment decoder module that has the two-bit input c1c0. This

ID: 1716234 • Letter: F

Question

Figure 6 shows a 7-segment decoder module that has the two-bit input c1c0. This decoder produces seven outputs that are used to display a character on a 7-segment display. Table 1 lists the characters that should be displayed for each valuation of c1c0. Three characters are included plus the 'blank' character, which is selected for code 11. The seven segments in the display are identified by the indices 0 to 6 shown in the figure. Each segment is illuminated by driving it to the logic value 0. You are to write a Verilog module that implements logic functions that represent circuits needed to activate each of the seven segments. Use only simple Verilog assign statements in your code to specify each logic function using a Boolean expression.

Explanation / Answer

module segment7dec (output reg [6:0] display, input [1:0] C);
always @* begin
case(C)
2'b0000: display = 7'b0100001;
2'b0001: display = 7'b0000110;
2'b0010: display = 7'b1111001;
2'b0011: display = 7'b1111111;
default: display = 7'b1111111;
endcase
display = ~display;
end
endmodule

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote