|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?注册
x
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_arith.all;
use ieee.std_logic_unsigned.all;
entity test2 is
port(x,clk:in std_logic;
sign,absval: out std_logic
);
end test2;
architecture behave of test2 is
signal b:std_logic:='1';
signal a:std_logic:='1';
begin
process(clk)
begin
if clk'event and clk='1' then
b<=x;
end if;
end process;
process(clk)
begin
if clk'event and clk='0' then
absval<=(a xor x);
sign<=(b xor x);
a<=x;
end if;
end process;
上面是我写的一个超前滞后异或门鉴相器,为什么功能仿真时sign,absval的波形是对的,而到了时序仿真时波形就出错了呢?请大家帮帮忙,给解答一下 |
|