V
vedpsingh
Hi all,
The code given below has perfectly compiled, but is not giving integer
output.
What am I doing wrong?
Thanks
ved
LIBRARY ieee;
USE ieee.std_logic_1164.ALL;
USE ieee.std_logic_arith.ALL;
USE ieee.std_logic_unsigned.ALL;
ENTITY conv_vec_int IS
PORT ( a : IN std_logic_vector(7 downto 0);
b : OUT integer range 0 to 255
);
END conv_vec_int;
ARCHITECTURE behav_conv_vec_int OF conv_vec_int IS
SIGNAL ai : std_logic_vector(7 downto 0);
SIGNAL bi : integer range 0 to 255;
BEGIN
ai <= a;
-- convert a from std_logic_vector to integer
bi <= bi* (conv_integer(ai));
END behav_conv_vec_int;
The code given below has perfectly compiled, but is not giving integer
output.
What am I doing wrong?
Thanks
ved
LIBRARY ieee;
USE ieee.std_logic_1164.ALL;
USE ieee.std_logic_arith.ALL;
USE ieee.std_logic_unsigned.ALL;
ENTITY conv_vec_int IS
PORT ( a : IN std_logic_vector(7 downto 0);
b : OUT integer range 0 to 255
);
END conv_vec_int;
ARCHITECTURE behav_conv_vec_int OF conv_vec_int IS
SIGNAL ai : std_logic_vector(7 downto 0);
SIGNAL bi : integer range 0 to 255;
BEGIN
ai <= a;
-- convert a from std_logic_vector to integer
bi <= bi* (conv_integer(ai));
END behav_conv_vec_int;