Forum Discussion
Altera_Forum
Honored Contributor
8 years agoHelp multiplier vhdl
Hi everyone! I've some problems with a design, I have to Design an algorithmic state machine to implement a parallel series multiplier for eight-bit numbers encoded in SM (Sign-Magnitude). The mul...
Altera_Forum
Honored Contributor
8 years ago --- Quote Start --- At least you got something... if it was me I will run a 7 states machine (or just a counter 0 to 6). Assuming y = A*B then I might go as below
case count is
when 0 =>
if A(0) = '1' then
temp <= B;
else
temp <= "0000000";
end if;
y <= y + temp; -- first of 7 additions, initialise y to zero
when 1 =>
if A(1) = '1' then
temp <= B;
else
temp <= "0000000";
end if;
y <= y + temp&'0'; --increase weight by one digit
...etc
you will need to declare proper types and manage bitwidth for addition. --- Quote End --- Sorry but I can´t understand what you want to do. Can you explain me?