推荐星级:
  • 1
  • 2
  • 3
  • 4
  • 5

对基带信号进行MASK调制VHDL程序及仿真

更新时间:2020-07-02 19:08:59 大小:60K 上传用户:xzxbybd查看TA发布的资源 标签:基带信号mask调制vhdl 下载积分:2分 评价赚积分 (如何评价?) 收藏 评论(0) 举报

资料介绍

--文件名:PL_MASK

--功能:基于VHDL硬件描述语言,对基带信号进行MASK调制

--说明:这里MASK中的M4

--最后修改日期:2004.2.13

library ieee;

use ieee.std_logic_arith.all;

use ieee.std_logic_1164.all;

use ieee.std_logic_unsigned.all;

entity PL_MASK is

port(clk      :in std_logic;                    --系统时钟

     start    :in std_logic;                    --开始调制信号

     x      :in std_logic;                    --基带信号

     y      :out std_logic_vector(7 downto 0));  --8DAC数据

end PL_MASK;

architecture behav of PL_MASK is

signal q:integer range 0 to 7;                   --计数器

signal qq:integer range 0 to 3;                  --计数器

signal xx:std_logic_vector(3 downto 0);          --并行数据寄存器

signal yy:std_logic_vector(7 downto 0);          --8DAC数据寄存器

begin

process(clk) --此进程完成基带信号的串并转换,完成4位并行数据到8DAC数据的译码

begin

if clk'event and clk='1' then

   if start='0' then q<=0;

   elsif q=0 then q<=1;xx(3)<=x;    

      if xx(3)='1' then yy<=xx&"1111";   --if语句完成4位并行数据到8DAC数据转换

      elsif xx(2)='1' then yy<=xx&"1011";

      elsif xx(1)='1' then yy<=xx&"0111";

      elsif xx(0)='1' then yy<=xx&"0011";

      else yy<=xx&"0000";

      end if;

   elsif q=2 then q<=3;xx(2)<=x;

   elsif q=4 then q<=5;xx(1)<=x;

   elsif q=6 then q<=7;xx(0)<=x;

   else  q<=q+1;

   end if;

end if;

end process;

process(clk)                                        --8DAC数据进行ASK调制

begin

if clk'event and clk='1' then


部分文件列表

文件名 大小
MASK调制VHDL程序及仿真.doc 60K

全部评论(0)

暂无评论