User:YEAH TOAST4555/Combinational logic

Advanced electronic mechanisms are mechanisms that deal with more  complicated Redstone circuitry.

Combinational Chips
Using logic gates, we can  arrange them to make binary calculations, like in a  computer. When using the gates below, mind the inputs and outputs. You may be wondering why  there are so many inverted signals being used  instead of the regular  signal. The adders below use XNOR gates rather than XOR gates because  they are more compact. As a result, IMPLIES gates must be used instead  of an AND gate, which also happen to be more  compact. Therefore for the most compact adder, inverse signals must be  used. These adders are too complex to be easily deciphered with 2  layers per square, so each single  layer has been drawn separately to  ease the building process.

Half Adder


Gates: XNOR, IMPLIES

Torches: 12

Redstone: 7

Blocks: 19

Size: 5X4X4

This  adder will take 2 bits and add them together. The resulting bit will be  the output of S (sum). If both bits are 1, there will be a carry over,  and C will become 1 ( C will become 0). This half adder can be modified  to create a non inverted C output, but this  configuration is used so  that it can be implemented as the start of a  chain of full adders.

Full Adder (1 Bit Adder)
AS A FOREWARNING THIS DESIGN IS WRONG! It uses an OR instead of an AND to combine the two half adders.



Gates: XNOR (2), IMPLIES, NOT, OR, AND

Torches: 16

Redstone: 32

Blocks: 48

Size: 6X12X5 Ceiling to floor, including I/O spaces.

This  adder will take 2 bits and a carried over bit (actually C, rather than  C, a  value held in the redstone in the bottom left corner on layer 1)  and  add them all together, producing a sum (S) bit and a carry (actually  C rather than  C).

4 Bit Adder


'''Note! The least significant digit ("ones" digit) is on the left of the  diagram so that the progression from half adder to the full adders can   be seen more clearly. Reverse the diagram if you want a conventional  left to right input.'''

Gates: XNOR (7), IMPLIES (4), NOT (4), OR (3), AND (3)

Torches: 56

Redstone: 108

Blocks: 164

Size: 23X12X5

This  adder will take 2, 4 bit numbers (A and B) and add them together,   producing a sum (S) bit for each bit added and a carry (C) for the whole   sum. The sum bits are in the same order as the input bits, which on the  diagram means that the leftmost S output is the least significant  digit  of the answer. This is just an example of a string of adders; adders  can be strung in this way to add bigger numbers as well.

Related pages

 * Redstone
 * Redstone Wire
 * Redstone Ore
 * Redstone Dust
 * Redstone Torch
 * Redstone circuits
 * Mechanisms
 * Traps