childs
Member level 5
I am having some problems with quartus 2 that i can't solve.... ><
Referring to the short modified code as below, I would like to compare the data in B with A, however the compilation does not allow this comparison, even though both the array A & B are formed by type "BYTE". Any idea how to fix this problem??
......
TYPE BYTE6 IS ARRAY (0 to 5) OF std_logic_vector(7 downto 0);
TYPE BYTE3 IS ARRAY (0 to 2) OF std_logic_vector(7 downto 0);
......
SIGNAL A: BYTE6 := (OTHERS => x"00");
SIGNAL B: BYTE3 := (OTHERS => x"00");
SIGNAL C: std_logic := '0';
......
IF (A(0 to 2) = B) THEN
C <= '1';
ELSE
C <= '0';
END IF;
......
Referring to the short modified code as below, I would like to compare the data in B with A, however the compilation does not allow this comparison, even though both the array A & B are formed by type "BYTE". Any idea how to fix this problem??
......
TYPE BYTE6 IS ARRAY (0 to 5) OF std_logic_vector(7 downto 0);
TYPE BYTE3 IS ARRAY (0 to 2) OF std_logic_vector(7 downto 0);
......
SIGNAL A: BYTE6 := (OTHERS => x"00");
SIGNAL B: BYTE3 := (OTHERS => x"00");
SIGNAL C: std_logic := '0';
......
IF (A(0 to 2) = B) THEN
C <= '1';
ELSE
C <= '0';
END IF;
......