为什么VHDL语言实体定义了三个个输入端口,两个输出,生成的器件图怎么少了两个端口。一位的端口都没了。
LIBRARYIEEE;USEIEEE.STD_LOGIC_1164.ALL;ENTITYmuxISPORT(clk,s:INSTD_LOGIC;lab:INSTD_LO...
LIBRARY IEEE;
USE IEEE.STD_LOGIC_1164.ALL;
ENTITY mux IS
PORT(clk,s:IN STD_LOGIC;
lab:IN STD_LOGIC_VECTOR(7 DOWNTO 0);
l:OUT STD_LOGIC_VECTOR(7 DOWNTO 0);
q:OUT STD_LOGIC_VECTOR(7 DOWNTO 0));
END mux;
ARCHITECTURE behav OF mux IS
BEGIN
PROCESS(s,clk)
BEGIN
IF s='1' THEN
IF clk'EVENT AND clk='1' THEN q<=lab;
ELSIF clk'EVENT AND clk='0' THEN q<=l;
END IF;
ELSE q<=lab;
END IF;
END PROCESS;
END;
新手···心理脆弱··请勿嘲笑 展开
USE IEEE.STD_LOGIC_1164.ALL;
ENTITY mux IS
PORT(clk,s:IN STD_LOGIC;
lab:IN STD_LOGIC_VECTOR(7 DOWNTO 0);
l:OUT STD_LOGIC_VECTOR(7 DOWNTO 0);
q:OUT STD_LOGIC_VECTOR(7 DOWNTO 0));
END mux;
ARCHITECTURE behav OF mux IS
BEGIN
PROCESS(s,clk)
BEGIN
IF s='1' THEN
IF clk'EVENT AND clk='1' THEN q<=lab;
ELSIF clk'EVENT AND clk='0' THEN q<=l;
END IF;
ELSE q<=lab;
END IF;
END PROCESS;
END;
新手···心理脆弱··请勿嘲笑 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询