
- UID
- 116228
- 性别
- 男
|
bs 为宽脉冲(位同步),fsk为窄脉冲(经过调频的),求每个宽脉冲内窄脉冲个数
就是用计数器解调2fsk的部分电路
总出错:non-locally-static attribute names are not supported
在怎么回事
有人会编写2fsk解调的vhhl 程序吗
我快疯了
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_arith.all;
use ieee.std_logic_unsigned.all;
entity jsq is
port(fsk:in std_logic;
bs:in std_logic;
q ut std_logic_vector(2 downto 0));
end entity jsq;
architecture behave of jsq is
signal tt:std_logic_vector(2 downto 0);
signal temp:std_logic;
begin
p1:process(bs)
begin
if bs'event then
temp<= '0';
else temp<='1';
end if;
end process p1;
p2:process(fsk)
begin
if temp='0'then
tt<="000";
elsif(fsk'event and fsk='1') then
tt<=tt+1;
end if;
q<=tt;
end process p2;
end architecture behave; |
|