小编Kat*_*lou的帖子

避免在VHDL中使用inout

我想避免在以下代码中使用inout.

有什么办法可以吗?例如一个帮助信号?

entity LA_Unit is
    Port ( Cin : in    STD_LOGIC;
           P   : in    STD_LOGIC_VECTOR (3 downto 0);
           G   : in    STD_LOGIC_VECTOR (3 downto 0);
           C3  : out   STD_LOGIC;
           C   : inout STD_LOGIC_VECTOR (2 downto 0));
end LA_Unit;

architecture Behavioral of LA_Unit is
begin
  C(0) <= (P(0) and Cin) xor G(0);
  C(1) <= (P(1) and C(0)) xor G(1);
  C(2) <= (P(2) and C(1)) xor G(2);
  C3   <= (P(3) and C(2)) xor G(3);
end Behavioral;
Run Code Online (Sandbox Code Playgroud)

vhdl inout

2
推荐指数
1
解决办法
475
查看次数

标签 统计

inout ×1

vhdl ×1