ch81现代数字系统设计基础.ppt

乘法器顶层原理图 8.4.2 相加-移位乘法器设计 乘法器仿真时序图 8.4.2 相加-移位乘法器设计 8.4.3 信号发生器设计 依次完成以下实验内容 (1)产生固定频率的锯齿波。 (2)产生固定频率的正弦信号,正弦信号的每个周期由256个采样点组成。 8.4.3 信号发生器设计 (3)利用DDS技术实现输出正弦信号频率步进可调,输出正弦信号频率范围为1kHz~10kHz,1kHz步进可调。输出频率采用两位LED数码管显示。 8.4.3 信号发生器设计 * architecture one of decoder is begin process(din) begin case din is when“0000”=led7s=“1000000”; when“0001”=led7s=“1111001”; when“0010”=led7s=“0100100”; when“0011”=led7s=“0110000”; when“0100”=led7s=“0011001”; when“0101”=led7s=“0010010”; when“0110”=led7s=“0000010”; when“0111”=led7s=“1111000”; 8.4.1 4位数字频率计设计 when“1000”=led7s=“0000000”; when“1001”=led7s=“0010000”; when“1010”=led7s=“0001000”; when“1011”=led7s=“0000011”; when“1100”=led7s=“1000110”; when“1101”=led7s=“0100001”; when“1110”=led7s=“0000110”; when“1111”=led7s=“0001110”; when others=led7s=null; end case; end process; end; 8.4.1 4位数字频率计设计 (4)CONTROL模块 library ieee; use ieee.std_logic_1164.all; entity control is port(clk:in std_logic; cs,clr,le:out std_logic); end control; 8.4.1 4位数字频率计设计 architecture behav of control is signal current_state,next_state:std_logic_vector(3 downto 0); constant st0:std_logic_vector:=“0011”; constant st1:std_logic_vector:=“0010”; constant st2:std_logic_vector:=“0110”; constant st3:std_logic_vector:=“0111”; constant st4:std_logic_vector:=“0101”; constant st5:std_logic_vector:=“0100”; constant st6:std_logic_vector:=“1100”; constant st7:std_logic_vector:=“1101”; constant st8:std_logic_vector:=“1111”; constant st9:std_logic_vector:=“1110”; 8.4.1 4位数字频率计设计 com1:process(current_state) begin case current_state is when st0=next_state=st1;clr=‘1’;cs=‘0’;le=‘0’; when st1=next_state=st2;clr=‘0’;cs=‘1’;le=‘0’; when st2=next_state=st3;clr=‘0’;cs=‘1’;le=‘0’; when st3=next_state=st4;clr=‘0’;cs=‘1’;le=‘0’; when st4=next_state=st5;clr=‘0’;cs=‘1’;le=‘0’; when st5=next_state=st6;clr=‘0’;cs=‘1’;le=‘0’; when st6=next_state=st7;clr=‘0’;cs=‘1’;le=‘0’; when st7=n

文档评论(0)

1亿VIP精品文档

相关文档