Hi,
I am trying to add an integer to an integer variable in VHDL, but when I try to synthesise it in XST I get:
"ERROR:Xst:1549 - controller.vhd line 331: Range bound must be a constant."
I have a bus (7 downto 0) that I convert to an integer using CONV_INTEGER, then try to add it to a variable using the following code:
totalLogCount := totalLogCount + CONV_INTEGER(internalBus);
The definitions are:
variable totalLogCount : integer;
and
internalBus : inout std_logic_vector(7 downto 0);
I use similar lines elsewhere in the code, but only ever adding 1 (e.g. "x := x + 1;", and this seems to be synthesisable.
Any help would be most appreciated.
Thanks,
Chris.
I am trying to add an integer to an integer variable in VHDL, but when I try to synthesise it in XST I get:
"ERROR:Xst:1549 - controller.vhd line 331: Range bound must be a constant."
I have a bus (7 downto 0) that I convert to an integer using CONV_INTEGER, then try to add it to a variable using the following code:
totalLogCount := totalLogCount + CONV_INTEGER(internalBus);
The definitions are:
variable totalLogCount : integer;
and
internalBus : inout std_logic_vector(7 downto 0);
I use similar lines elsewhere in the code, but only ever adding 1 (e.g. "x := x + 1;", and this seems to be synthesisable.
Any help would be most appreciated.
Thanks,
Chris.