Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Multiplexers Multiplexers (also called muxes) are an important part of computer design, and have a wide variety of applications. The purpose of a multiplexer is

Multiplexers Multiplexers (also called muxes) are an important part of computer design, and have a wide variety of applications. The purpose of a multiplexer is to select 1 of n inputs to output. So naturally, it has some set number of inputs to choose from, and then it as log(n) bits to use as a selection mechanism. Here is the block diagram for a 2-way mux:

For this lab assignment you will construct a mux for 2-1 and 4-1 muxes.

https://www.edaplayground.com/x/4C28

Please submit the design file as mux.sv

`default_nettype none

module mux2(input [1:0] in, input sel, output out);

endmodule

module mux4(input [3:0] in, input [1:0] sel, output out);

endmodule

Bonus: However, it should be noted that rather than trying to implement each from scratch, it is possible to implement larger muxes by embedding smaller ones. For this bonus question, design a 8-1 multiplexer using 4-1 and 2-1 multiplexers in verilog. The skeleton code for the 2, 4, and way muxes is provided here: https://www.edaplayground.com/x/3EZc

module mux2(input [1:0] in, input sel, output out);

endmodule

module mux4(input [3:0] in, input [1:0] sel, output out);

endmodule

module mux8(input [7:0] in, input [2:0] sel, output out);

endmodule

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Pro SQL Server Administration

Authors: Peter Carter

1st Edition

1484207106, 9781484207109

More Books

Students also viewed these Databases questions