[an error occurred while processing this directive]
|
есть у меня к примеру такое
ADDR1 : in STD_LOGIC_VECTOR(2 downto 0);
ADDR2 : in STD_LOGIC_VECTOR(18 downto 16);
и есть 2 case'а
case ADDR1 is
when "001" => tmp(4 downto 0) <= "11110";
when "010" => tmp(4 downto 0) <= "11101";
when "011" => tmp(4 downto 0) <= "11011";
when "100" => tmp(4 downto 0) <= "10111";
when "101" => tmp(4 downto 0) <= "01111";
when others => tmp(4 downto 0)<= "11111";
end case;
case ADDR2 is
when "001" => tmp(6 downto 5) <= "10";
when "010" => tmp(6 downto 5) <= "01";
when others => tmp(6 downto 5)<= "11";
end case;
можноли засунуть это всё дело в один CASE ???
что-то типа
case ADDR1 is
when "001" => tmp <= "1111110";
when "010" => tmp <= "1111101";
...
when ADDR2="001" => tmp <= "1011111";
when ADDR2="010" => tmp <= "0111111";
when others => tmp <= "1111111";
end case;
или каким макаром это лучше сделать ?
или мне всё это через оператор if делать ?
E-mail: info@telesys.ru