S
Sebastien Bourdeauducq
Guest
Hi,
I'd like to compute the arithmetic sum of a NATURAL signal and a
STD_LOGIC_VECTOR signal, and store the value into a NATURAL signal,
ie. a <= b + c, with a NATURAL, b NATURAL and c STD_LOGIC_VECTOR.
How should I do ? Here the compiler complains about not finding a
suitable definition of the + operator. I tried various combinations of
TO_INTEGER(), TO_BIT_VECTOR(), UNSIGNED(), ... but no luck.
The sum works when all operands are NATURAL.
I'm using Quartus II from Altera.
Regards,
Sebastien
I'd like to compute the arithmetic sum of a NATURAL signal and a
STD_LOGIC_VECTOR signal, and store the value into a NATURAL signal,
ie. a <= b + c, with a NATURAL, b NATURAL and c STD_LOGIC_VECTOR.
How should I do ? Here the compiler complains about not finding a
suitable definition of the + operator. I tried various combinations of
TO_INTEGER(), TO_BIT_VECTOR(), UNSIGNED(), ... but no luck.
The sum works when all operands are NATURAL.
I'm using Quartus II from Altera.
Regards,
Sebastien