Advertisement
CoMoDoS

display7seg

May 15th, 2018
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VHDL 1.45 KB | None | 0 0
  1. ----------------------------------------------------------------------------------
  2. -- Company:         UTCN
  3. -- Engineer:
  4. --
  5. -- Create Date:     02/04/2016 10:12:56 AM
  6. -- Design Name:     displ7seg
  7. -- Module Name:     displ7seg - Behavioral
  8. -- Project Name:
  9. -- Target Devices:  Nexys4 DDR (xc7a100tcsg324-1)
  10. -- Tool Versions:   Vivado 2015.4, Vivado 2016.4
  11. -- Description:     Multiplexor pentru afisajul cu 7 segmente
  12. --                  Datele de la intrare se interpreteaza ca valori hexazecimale
  13. --                  si sunt decodificate in configuratia segmentelor afisajului
  14. --
  15. -- Dependencies:
  16. --
  17. -- Revision:
  18. -- Revision 0.01 - File Created
  19. -- Additional Comments:
  20. --
  21. ----------------------------------------------------------------------------------
  22.  
  23. library IEEE;
  24. use IEEE.STD_LOGIC_1164.ALL;
  25. use IEEE.STD_LOGIC_UNSIGNED.all;
  26. use IEEE.STD_LOGIC_ARITH.all;
  27.  
  28. entity display7seg is
  29.     Port ( Clk  : in  STD_LOGIC;
  30.            Rst  : in  STD_LOGIC;
  31.            Data : in  STD_LOGIC_VECTOR (7 downto 0);   -- datele pentru 8 cifre (cifra 1 din stanga: biti 31..28)
  32.            An   : out STD_LOGIC_VECTOR (7 downto 0);    -- selectia anodului activ
  33.            Seg  : out STD_LOGIC_VECTOR (7 downto 0));   -- selectia catozilor (segmentelor) cifrei active
  34. end display7seg;
  35.  
  36. architecture Behavioral of display7seg is
  37. begin
  38.     An<="11111110";
  39. decoder: entity work.scancodeTochar
  40.     port map(scancode=>Data,char=>Seg);
  41. end Behavioral;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement