📄 page3.vhd
字号:
--------------------------------------------------------------------------------
-- Company:
-- Engineer:
--
-- Create Date: 06:31:19 03/25/05
-- Design Name:
-- Module Name: page3 - Behavioral
-- Project Name:
-- Target Device:
-- Tool versions:
-- Description:
--
-- Dependencies:
--
-- Revision:
-- Revision 0.01 - File Created
-- Additional Comments:
--
--------------------------------------------------------------------------------
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
---- Uncomment the following library declaration if instantiating
---- any Xilinx primitives in this code.
--library UNISIM;
--use UNISIM.VComponents.all;
entity page3 is
Port ( en : in std_logic_vector(4 downto 0);
addr: in std_logic_vector(4 downto 0);
din : in std_logic_vector(7 downto 0);
dint : in std_logic_vector(19 downto 0);
dout : out std_logic_vector(7 downto 0));
end page3;
architecture Behavioral of page3 is
begin
process(en,din,addr)
begin
if en="10011" then
case addr is
when "11000"=>
dout<="0011"&dint(19 downto 16);
when "11010"=>
dout<="0011"&dint(15 downto 12);
when "11011"=>
dout<="0011"&dint(11 downto 8);
when "11100"=>
dout<="0011"&dint(7 downto 4);
when "11101"=>
dout<="0011"&dint(3 downto 0);
when others=>
dout<=din;
end case;
end if;
end process;
end Behavioral;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -