Digital logic---Touge training homework---Multiplexer design and application (Logisim)

Level 1: 2-to-1 selector design

If you have any doubts or want the final experimental code, you can shout in the comment area. I hope my answer will be helpful to you. Please pay attention and go, thank you! ! !

The final answer for this level:

mission details

  1. The task of this level: draw a 2-to-1 multiplexer in Logisim, complete the test locally, experience the function of data selection, and then complete the evaluation online.

related information

A multiplexer, also known as a data selector, multiplexer, or multiplexer (MUX, Multiplexer), is a circuit that can select any one of the data to be sent to the output end according to the need in the process of multiplexing data transmission. The schematic diagram of the 2-to-1 multiplexer circuit is as follows:

mux2-1

The simplified truth table of the 2-way selector is as follows:

s f
0 w0​
1 w1​

Expression: On the basis of this figure, use the blocking feature of the gate circuit to construct the enable signal, and pay attention to the output value when the enable is invalid.f=sw0+sw1

Pin Description

Signal I / O bit width illustrate
nEnable enter 1 person Enable terminal, active low. Select when nEnable=0; disable selection when nEnable=1, the output is always 1 at this time.
Select enter 1 person Address Selection (Data Port Selection)
D1, D0 enter 1 person 2 data input
F output 1 person data output

Subcircuit appearance

MUX21

Do not move the pin position or the test will not be completed!

Experimental content

Experimental circuit framework MUXlab.circ download: Right-click the code area on the right, Download File

,

Open the experimental circuit framework in Logisim, and complete the selector design in the "2-to-1 MUX" subcircuit in the project.

test introduction

After the local experiment is completed, please open the circuit file (MUXlab.circ) with Notepad or other plain text editor, select all, copy, and paste it into the Educoder code window, click the "Evaluation" button at the bottom right, and the platform will evaluate you. code to test.

Level 2: 4-to-1 selector design

If you have any doubts or want the answer code, you can call me in the comment area, I hope my answer will be helpful to you, click on it and go, thank you! ! !

The final answer for this level:

mission details

The task of this level: Use the 2-to-1 selector of the previous level to cascade design a 4-to-1 multiplexer in Logisim.

related information

A multiplexer, also known as a data selector, multiplexer, or multiplexer (MUX, Multiplexer), is a circuit that can select any one of the data to be sent to the output end according to the need in the process of multiplexing data transmission. The 4-to-1 selector cascade expansion principle is as follows:

mux4-1

The simplified truth table of the 4-way selector is as follows:

s1​ s0​ f
0 0 w0​
0 1 w1​
1 0 w2​
1 1 w3​

The expression is as follows: is the minimum term f=s1​s0​w0​+s1​s0​w1​+s1​s0​w2​+s1​s0​w3​ =m0​w0​+m1​w1​+m2​w2​+m3​w3​=∑i=03​mi​wi​ mi​of the selection variable , is the data inputs1​,s0​wi​

Pin Description

Signal I / O bit width illustrate
nEnable enter 1 person Enable terminal: select when nEnable=0; disable selection when nEnable=1, the output is always 1 at this time.
Select enter 2 bits Address selection
D3~D0 enter 1 person 4 data inputs
F output 1 person data output

Subcircuit appearance

MUX41

Do not move the pin position or the test will not be completed!

Experimental content

The experimental circuit framework is the same as the first level, open the experimental circuit framework in Logisim, and complete the selector design in the "4 choose 1 MUX" subcircuit.

test introduction

After the local experiment is completed, please open the circuit file (MUXlab.circ) with Notepad or other plain text editor, select all, copy, and paste it into the Educoder code window, click the "Evaluation" button at the bottom right, and the platform will evaluate you. code to test.

Level 3: 1 out of 8 selector design

If you have any doubts or want the answer code, you can call me in the comment area, I hope my answer will be helpful to you, click on it and go, thank you! ! !

The final answer for this level:

mission details

The task of this level: Use the selectors of the previous two levels to cascade to design an 8-to-1 multiplexer.

related information

A multiplexer, also known as a data selector, multiplexer, or multiplexer (MUX, Multiplexer), is a circuit that can select any one of the data to be sent to the output end according to the need in the process of multiplexing data transmission. The simplified truth table of the 8-way selector is as follows:

s2​ s1​ s0​ f
0 0 0 w0​
0 0 1 w1​
0 1 0 w2​
0 1 1 w3​
1 0 0 w4​
1 0 1 w5​
1 1 0 w6​
1 1 1 w7​

The expression is as follows: is the minimum term f=∑i=07​mi​wi​ mi​of the selection variable , is the data inputs2​,s1​,s0​wi​

Pin Description

Signal I / O bit width illustrate
nEnable enter 1 person Enable terminal: select when nEnable=0; disable selection when nEnable=1, the output is always 1 at this time.
Select enter 3 digits Address selection
D7~D0 enter 1 person 8 data inputs
F output 1 person data output

Subcircuit appearance

MUX81

Do not move the pin position or the test will not be completed!

Experimental content

The experimental circuit framework is the same as the first level, open the experimental circuit framework in Logisim, and complete the selector design in the "8-to-1 MUX" subcircuit.

test introduction

After the local experiment is completed, please open the circuit file (MUXlab.circ) with Notepad or other plain text editor, select all, copy, and paste it into the Educoder code window, click the "Evaluation" button at the bottom right, and the platform will evaluate you. code to test.

Level 4: Application of the Multiplexer

If you have any doubts or want the answer code, you can call me in the comment area, I hope my answer will be helpful to you, click on it and go, thank you! ! !

The final answer for this level:

mission details

The task of this level: Select the multiplexer designed in the previous level in Logisim to design the combinational logic and design the full adder FA.

related information

For the way selector, the expression is as follows: is the minimum term of the selection variable , is the data input2nf=∑i=02n−1​miwi misn−1​…s0​wi

truth table transformation

Principle: Transform the truth table of the function to be implemented into a simplified truth table form corresponding to the multiplexer! For example: use 4 to choose 1 MUX to realize the 3-input multi-function functionf(w1​,w2​,w3​)=Σm(3,5,6,7)

,

Use 4 to choose 1 MUX to achieve as follows:

,

w1​,w2​作为选择变量s1​,s0​,将0w3w3​1分别接入0号、1号、2号和3号数据端口。注意函数变量与选择变量的对应顺序!! 若用8选1MUX实现3输入函数,则真值表无需做任何变换! 此时,w1​,w2​,⋯,w8​作为选择变量s7​,s6​,⋯,s0​,将8个函数值分别送入对应数据端口。

香农展开(1变量展开)

任何n变量函数f(w1​,w2​,⋯,wn​)可以对w1​展开表示为: f=w1​⋅f(0,w2,,wn)+w1​⋅f(1,w2,,wn) =w1​⋅fw1+w1​⋅fw1 对任意wi展开都有效! 此时可以用2选1MUX实现该函数,如图所示:

,

w1​作为选择变量s,将fw1fw1的逻辑实现分别接入0号和1号数据端口。

香农展开(2变量展开)

任何n变量函数f(w1​,w2​,w3​,⋯,wn​)可以对w1​,w2​展开表示为: f=w1​w2​⋅f(0,0,w3,,wn)+w1​w2​⋅f(0,1,w3,,wn) +w1​w2​⋅f(1,0,w3​,⋯,wn​)+w1​w2​⋅f(1,1,w3,,wn) =w1​w2​⋅fw1w2+w1​w2​⋅fw1w2+w1​w2​⋅fw1​w2​​+w1​w2​⋅fw1w2 对任意wi​,wj​(i​=j)展开都有效! 此时可以用4选1MUX实现该函数,如图所示:

,

w1​,w2​作为选择变量s1​,s0​,将fw1w2fw1w2fw1​w2​​fw1w2的逻辑实现分别接入0号、1号、2号和3号数据端口。 依此类推,可以对任意的k个变量展开(kn),然后用2k选1MUX实现该函数!当k=n时,展开式为函数的正则SOP式(标准与或式)。

引脚说明

信号 I/O 位宽 说明
nEnable 输入 1位 使能端:nEnable=0时做加法;nEnable=1禁止相加,此时输出恒为1。
A,B,Ci 输入 1位 三个相加数
Co,Sum 输出 1位 进位输出、和输出

子电路外观

FA

请勿移动引脚位置,否则无法完成测试!

Experimental content

The experimental circuit framework is the same as the first level, open the experimental circuit framework in Logisim, and complete the design of the full adder in the "MUX application" subcircuit.

test introduction

After the local experiment is completed, please open the circuit file (MUXlab.circ) with Notepad or other plain text editor, select all, copy, and paste it into the Educoder code window, click the "Evaluation" button at the bottom right, and the platform will evaluate you. code to test.

Extended Design Suggestions

The circuit design and realization of more functions with different variable numbers can be completed locally by using MUX.

Guess you like

Origin blog.csdn.net/weixin_52333648/article/details/122381390