Forum Discussion
Altera_Forum
Honored Contributor
7 years ago --- Quote Start --- Hi, I understand your point. But the when you actually coding, you can't just do a pack based on a fixed number, right? because the exponent value is different. So, are you suggesting to write a case statement to hard code the logic? If not, could you please give me some hints on this, because the only other way I figure out to do this is through a shifting register. Thank you very much! --- Quote End --- yes you put the logic but no need to wait, e.g.
case exponent is
when -3 =>
re_sc <= re(28 downto 0) & "000";
im_sc <= im(28 downto 0) & "000";
when -4 =>
re_sc <= re(27 downto 0) & "0000";
im_sc <= im(27 downto 0) & "0000";