文档库 最新最全的文档下载
当前位置:文档库 › Lab_Report11

Lab_Report11

Lab_Report11
Lab_Report11

Digital Circuit & Logic Design

Lab Report 1

Name:

Student No.:

Major: computer science and technology

Score:

1、Design an alarm for a dam. Use 4 bits to represent the water level. When the level reaches 8m, the green light is on; when it reaches 10m, the yellow light is on; and when it reaches 12m, the red light is on. The water level would never reach 14m, and only one light is on at one time. Design the control circuit of the alarm and implement it.

Principles: (How do you plan to solve the problems? Write down the logic functions of the outputs.)

2、First of all,we saw the requirements,founding that we should use 4 bits to represent the water level and when the level reaches 8m, the green light is on; when it reaches 10m, the yellow light is on; and when it reaches 12m, the red light is on.So we wrote the truth table and Simplified it.We get an expression finally.According to this expression,we solved the problem.

m0=AB`C`,the green light is on;

m1=AB`C, the yellow light is on;

m2=AB , the red light is on.

Implementation: (Your implementation details.)

1、Use NAND gate and NOT gate to finish the function of AND,then use Not gate make B`and C`,use 3 NAND and NOT gates to finish AB`C`;

2、Use NAND gate and NOT gate to finish the function of AND,then use Not gate make B`,use 3 NAND and NOT gates to finish AB`C;

3、Use NAND gate and NOT gate to finish the function of AND,then use 2 NAND and NOT gates to finish AB.

1、Design a two-bit binary adder.

Principles: (How do you plan to solve the problems? Write down the logic functions of the outputs.)

First of all,we saw the requirements,founding that we should input 5 bits.We saw the book,founding the 1-bit binary adder.So we firstly added the last bit with the cin,gotting a addition carry.We used the carry as a cin,and added it with the other bit.Finally we got the second bit and a cout.

S0=X⊕Y⊕CIN;

Carry=X·Y+X·CIN+Y·CIN;

S1=X1⊕Y1⊕Carry;

COUT=X1·Y1+X1·Carry+Y1·Carry.

Implementation: (Your implementation details.)

1、use two XOR gates,3 NAND gates and 3 NOT gates as 3 AND gates,3 NAND gates and 1 XOR gates as a OR gate,implement a 1-bit full adder ;

2、According the step1,we got S0 and carry,then we repeated step 1,regarding carry as cin.We got S1 and cout finally.

相关文档