Byte Adder

An area for asking questions, making suggestion, share ideas and place circuit examples.
Post Reply
GRX01
Posts: 5
Joined: Fri Apr 30, 2010 4:44 pm

Byte Adder

Post by GRX01 »

It adds bytes! Pretty simple, but it's my first actual accomplishment with LogicCircut. Sorry about all the wires and such :P. The bytes run vertically, with the 2^7 place on the top. So, 10001011 looks like:
1
0
0
0
1
0
1
1
You add the first two bytes (first two columns) and the result is the third column, which is presented as a byte plus carry-out (the carry-out is top bit on the third column, and the 2^7 place is below it). I made the adding mechanism without looking at a diagram for a proper adder, so I apologize for any inherent inefficiency.
Attachments
Byte Addition.zip
Adds bytes!
(33.52 KiB) Downloaded 1855 times
User avatar
admin
Site Admin
Posts: 417
Joined: Sun Jun 14, 2009 10:53 pm
Contact:

Re: Byte Adder

Post by admin »

Nice, you can also add a carry in bit so you can chain your adder to multi byte adder.
GRX01
Posts: 5
Joined: Fri Apr 30, 2010 4:44 pm

Re: Byte Adder

Post by GRX01 »

Done! And reduced file size by quite a bit by basing the byte adder off of smaller adders.
Attachments
Byte Addition.zip
improved
(25.68 KiB) Downloaded 1568 times
GRX01
Posts: 5
Joined: Fri Apr 30, 2010 4:44 pm

Re: Byte Adder

Post by GRX01 »

I'm back after so long :P
I've made a device that adds 4-bit numbers, but also displays them and the sum with the 7-segment display.
I know that an LCD controller chip already exists, but I think the one I've made is more efficient and organized. Rather than many AND gates and arrays of wires, I've worked out the optimum gates using Karnaugh maps. Took me half an hour just to finish the maps lol

EDIT: The LCD chip from the downloadable digital clock has less gates than mine XD Mine is a bit easier on the eyes though :P

It takes in a 4-bit number and outputs an 8-bit number which must be split and input into the display.
The 4BDS chip takes a 4-bit number and splits it into the 10's digit and 1's digit of its decimal equivalent. These are then fed to the LCD controller chip.

If you get a strange result, like 11 + 8 = 3, that means that the calculator has encountered an overflow (represented by the activation of the LED). Add 16 to the displayed result to get the actual result, if that's the case.

Also included is a Toggle chip, which is essentially a modified JK flip-flop. It changes value when the input falls from 1 to 0, making a button-based input perfect.
4-Bit adder with screen.CircuitProject
(191.33 KiB) Downloaded 1625 times
User avatar
admin
Site Admin
Posts: 417
Joined: Sun Jun 14, 2009 10:53 pm
Contact:

Re: Byte Adder

Post by admin »

Welcome back.
You’ve done a very good job. But I’ve found it gives incorrect result when numbers sum up to more than 10. Are you designed it this way or this is an error?
Eugene
GRX01
Posts: 5
Joined: Fri Apr 30, 2010 4:44 pm

Re: Byte Adder

Post by GRX01 »

It should give incorrect results if the sum is more than 15 because it overflows at that point (the output is a 4-bit number, and the highest decimal number that can be represented in 4 bits is 15)
If that isn't what is happening, the I've messed up somewhere lol
User avatar
TCWORLD
Posts: 13
Joined: Thu Sep 15, 2011 5:11 pm
Location: Leeds, England, UK
Contact:

Re: Byte Adder

Post by TCWORLD »

If you are still interested in a circuit to add two 4bit numbers and display the outpput on a pair of 7 segment display, I came up with one method a year or so ago fo some uni coursework. I can recreate it in logiccircuit if you want :)
Post Reply