File:Pistongates.png

Summary
Basic logic gates purely with pistons/repeaters, clockwise from upper left: AND, OR, XOR, and NOT. Note the only source of power is from levers or redstone torches. There are no NOT gates in redstone torches or any other sort of extraneous/supporting logic. Repeaters are used in most gates because power will not transmit to/from blocks any other way.