A
arthur merlo
Hi guys, I'm new in VHDL and would be glad if anyone could help me
with
my bcd-7segments decoder. I dont know why its not compiling
LIBRARY ieee;
USE ieee.std_logic_1164.all;
ENTITY decod_7seg IS
PORT (
a : IN STD_LOGIC_VECTOR(17 DOWNTO 0);
HEX0 : OUT STD_LOGIC_VECTOR(6 DOWNTO 0)
);
END decod_7seg;
ARCHITECTURE behaviour OF decod_7seg IS
BEGIN
HEX0 <= "1000000";
when a="0000"
else
HEX0 <= "1111001";
when a="0001"
else
HEX0<= "0100100";
when a="0010"
else
HEX0<= "0110000";
when a="0011"
else
HEX0 <= "0011001";
when a="0100"
else
HEX0<= "0100010";
when a="0101"
else
HEX0 <= "0000010";
when a="0110"
else
HEX0 <= "1111000";
when a="0111"
else
HEX0 <= "0000000";
when a="1000"
else
HEX0 <= "0010000";
when a="1001"
END behaviour;
with
my bcd-7segments decoder. I dont know why its not compiling
LIBRARY ieee;
USE ieee.std_logic_1164.all;
ENTITY decod_7seg IS
PORT (
a : IN STD_LOGIC_VECTOR(17 DOWNTO 0);
HEX0 : OUT STD_LOGIC_VECTOR(6 DOWNTO 0)
);
END decod_7seg;
ARCHITECTURE behaviour OF decod_7seg IS
BEGIN
HEX0 <= "1000000";
when a="0000"
else
HEX0 <= "1111001";
when a="0001"
else
HEX0<= "0100100";
when a="0010"
else
HEX0<= "0110000";
when a="0011"
else
HEX0 <= "0011001";
when a="0100"
else
HEX0<= "0100010";
when a="0101"
else
HEX0 <= "0000010";
when a="0110"
else
HEX0 <= "1111000";
when a="0111"
else
HEX0 <= "0000000";
when a="1000"
else
HEX0 <= "0010000";
when a="1001"
END behaviour;