IPO 发表于 2010-8-11 14:41:34

问题描述:在VHDL中,如何使用两个时钟更改同一个数据?

问题描述:在VHDL中,如何使用两个时钟更改同一个数据?

IPO 发表于 2010-8-11 14:41:51

解决方法:使用“异或”(xor)逻辑。示例如下:
process (clk1)
begin
if rising_edge(clk1) then
SIG_DOUT1 <= SIG_DOUT2 xor SIG_DIN1;
end if;
end process;
process (clk2)
begin
if rising_edge(clk2) then
SIG_DOUT2 <= SIG_DOUT1 xor SIG_DIN2;
end if;
end process;
SIG_DOUT <= SIG_DOUT1 xor SIG_DOUT2;
DOUT <= SIG_DOUT;
页: [1]
查看完整版本: 问题描述:在VHDL中,如何使用两个时钟更改同一个数据?