⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 switcher_bus.vhd

📁 此为FPGA上的一个串口通信程序
💻 VHD
字号:
--
library IEEE;
use IEEE.STD_LOGIC_1164.all;

entity switch_bus is
	generic(BUS_WIDTH:integer:=8);
	
	port(din1:in std_logic_vector(BUS_WIDTH-1 downto 0);
		 din2:in std_logic_vector(BUS_WIDTH-1 downto 0);
		 sel:in std_logic;
		 dout:out std_logic_vector(BUS_WIDTH-1 downto 0));
end switch_bus;

architecture switch_bus of switch_bus is
begin 
	with sel select
	dout<=din1 when '0',
		  din2 when others;
end switch_bus;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -