还剩7页未读,继续阅读
文本内容:
国家开放大学实验组合逻辑电路2的设计
一、试验目的
1、掌握组合逻辑电路的设计方法
2、掌握组合逻辑电路的静态测试方法
3、熟悉CPLD设计的过程,比较原理图输入和文本输入的优劣
二、实验的硬件要求
1、输入按键开关(常高)4个;拨码开关4位
2、输出:LED灯
3、主芯片:Altera EPM7128SLC84-15O
三、实验内容
1、设计一个四舍五入判别电路,其输入为8421BCD码,要求当输入大于或等于5时,判别电路输出为1,反之为
002、设计四个开关控制一盏灯的逻辑电路,要求改变任意开关的状态能够引起灯亮灭状态的改变(即任一开关的合断改变原来灯亮灭的状态)
3、设计一个优先排队电路,其框图如下排队顺序A=1最悬)优先级B=1次高优先级C=1最低优先级要求输出端最多只能有一端为〃]〃,即只能是优先级较高的输入端所对应的输出端为1
四、实验连线
1、四位拨码开关连D
3、D
2、Dl、DO信号对应的管脚OUT输出信号管脚接LED灯
2、四位按键开关分别连KI、K
2、K
3、K4信号对应的管脚OUT输出信号管脚接LED灯
3、A、B、C信号对应管脚分别连三个按键开关输出A_Out B_Outs sC_Out信号对应的管脚分别连三个LED灯具体管脚参数由底层管脚编辑决定
五、参考原理图
1、
①原理图,如图2-1所示
②VHDL硬件描述语言输入library ieee;use ieee.std_logic_
1164.all;use ieee.std_logic_signed.all;entity bcd_pjq isportdin:in integerrange15downto0;dout:out stdjogic;end;architecture aof bcd_pjq isbeginpl:processbeginif din5thendout=0;elsedout=l;end if;end processpl;end;
2、
①原理图,如图2-2所示:
②VHDL硬件描述语言输入:library ieee;use ieee.std_logic_
1164.all;entity led_control isportk0,kl,k2,k3:in stdjogic;y:out stdjogic;end;architecture oneof led_control issignaldz:stdjogic_vector3downto0;begindz=k3k2klkO;pl:processdzbegincase dzis when”0000=y=0;when0001=y=,l;when0011=y=,01;when0010=y=,l;when0110=y=0;when0111=7=1;when0101=y=,0,;when0100=y=,l;when1100=y=,0,;when1101=y=l;when,,llll=y=0;when1110=7=1;when1010=y=0;when1011=y=l;when1001=y=,0;when1000=y=,l;when others=y=X;end case;end processpl;end one;
3、
①原理图,如图2-3所示
②VHDL硬件描述语言输入library ieee;use ieee.std_logic_
1164.all;entity queue_prior isportab,c:in std_logic;zaout,bout,cout:out stdjogic;architecture oneof queue_prior isbeginpl:processbeginif a=l thenaout=l;bout=0;cout=0;elsif b=l thenaout=0;bout=l;cout=0;elsif c=l thenaout=0;bout=0;cout=l;elseaout=0;bout=0;cout=0;end if;end processpl;end one;
六、实验报告要求
1、对于原理图设计要求有设计过程
2、详细论述实验步骤
3、写一些对比两种硬件设计输入法的优劣的心得。
个人认证
优秀文档
获得点赞 0