北理工quartus实验二报告剖析

上传人:今*** 文档编号:105923543 上传时间:2019-10-14 格式:DOCX 页数:8 大小:1.72MB
返回 下载 相关 举报
北理工quartus实验二报告剖析_第1页
第1页 / 共8页
北理工quartus实验二报告剖析_第2页
第2页 / 共8页
北理工quartus实验二报告剖析_第3页
第3页 / 共8页
北理工quartus实验二报告剖析_第4页
第4页 / 共8页
北理工quartus实验二报告剖析_第5页
第5页 / 共8页
点击查看更多>>
资源描述

《北理工quartus实验二报告剖析》由会员分享,可在线阅读,更多相关《北理工quartus实验二报告剖析(8页珍藏版)》请在金锄头文库上搜索。

1、实验二 模十状态机与7段译码器显示一、实验目的:通过设计频率可选的模十状态机以及7段译码电路以进一步掌握VHDL硬件描述语言。二、实验流程:本设计有分频器、多路选择器、状态机和译码器。1. 时钟输入作为分频器的输入,输出时钟分别为2分频、4分频、8分频和16分频;2. 四个频率的时钟信号由4选1的多路选择器选择其中之一作为状态机的时钟输入;3.使用选中的时钟频率作为输入驱动状态机按照以下的次序输出:0-2-5-6-1-9-4-8-7-3-0的顺序输出;4. 使用此输出作为驱动输入到7段译码器的显示逻辑。三、实验代码:library IEEE;use IEEE.std_logic_1164.al

2、l;use IEEE.STD_LOGIC_ARITH.ALL;use IEEE.STD_LOGIC_UNSIGNED.ALL;entity mod10 isport(clk,rst,load:in std_logic;sel:in std_logic_vector(1 downto 0);countss:in std_logic_vector(3 downto 0);seg:out std_logic_vector(6 downto 0);end mod10;architecture beha of mod10 is signal clk1,clk2,clk4,clk8,clk16:std_l

3、ogic; signal count,q_temp:std_logic_vector(3 downto 0); signal counts:std_logic_vector(3 downto 0):=0000;begin process(clk,rst) -分频、rst:清零,低有效 begin if( rst = 0) thencount =0000; elsif( clkevent and clk =0) then count = count+1; end if; clk2 = count(0); clk4 = count(1); clk8 = count(2); clk16 clk1 c

4、lk1 clk1 clk1 null; end case;end process;process(clk1,rst,load) -load:置数,高有效, beginif(rst=0)then counts=0000;elsif(load=1)thencountscountscountscountscountscountscountscountscountscountscountscounts=0000;end case;end if;q_tempsegsegsegsegsegsegsegsegsegsegseg=0001000;end case;end process;end beha;四、实验结果1、功能仿真整体结果:二分频:四分频:八分频: 十六分频:2、时序仿真整体结果:二分频: 四分频:八分频:十六分频:五、实验心得: 做这个实验的时候花了很长的时间,算下来应该有足足一天时间吧。学的最多的是怎么将几个模块联系起来,以及理解了processing几个模块间都是并行运行的这个思想特别的深刻,这让模块间的联系简单了许多。另一个收获就是更加深刻的理解了quartus II语言的规则,让运用更加的得心应手。

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 高等教育 > 大学课件

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号