Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > VHDL > 4 bit adder with overflow check

Thread Tools

4 bit adder with overflow check

hexler hexler is offline
Junior Member
Join Date: Apr 2007
Posts: 1
Hi there,

I found this forum with google search, because I don't know any forum with VHDL topics.

I have successfully compiled a 4 bit adder with the port map method.
Now I want to check for an overflow and I've created a process that checks the last carry out.

But now I'am getting an error that my output bitvector has more than one sources. (Because VHDL is working parallel)

How can I fix this?

Here is my architecture:

Reply With Quote
martin.wahlstedt martin.wahlstedt is offline
Junior Member
Join Date: Mar 2007
Posts: 14
The error is correct, if t4='1', you are driving the output from two sources. One thing you can do is to use an internal signal (out_temp) from the two-adders and extend the process to

process(t4) begin
if (t4 = '1') then
output <= "1111";
else output <= "out_temp";
end if;
end process;

Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
overflow of adder in VHDL blckisle VHDL 1 05-03-2008 03:14 PM
n bit adder Lilmiss VHDL 0 07-24-2005 04:44 AM
Signed Adder without overflow Nemesis VHDL 4 05-25-2005 07:31 PM
how do you extract carry, borrow and overflow from an adder in vhdl? Rune Christensen VHDL 4 01-22-2005 11:17 PM
30 bit adder performance ALuPin VHDL 5 12-12-2004 10:22 PM