www.pudn.com > codeofvhdl2006.rar > COM_ENCODE.VHD


 
 
--com_encode.vhd 7 segment com encoder 
library ieee ; 
use ieee.std_logic_1164.all; 
entity com_encode is 
port( 
  com_clk : in std_logic_vector(1 downto 0);--input count 
  ledcom : out std_logic_vector(3 downto 0));--output encode 
end com_encode; 
architecture behavior of com_encode is  
begin  
  ledcom<="1110" when com_clk="00" else 
          "1101" when com_clk="01" else 
          "1011" when com_clk="10" else 
          "0111";                                         
end behavior;¡@