Signal, Charging, Activation: Three Easy Confusions
Redstone signal runs 0 to 15, losing 1 per block of dust; repeaters restore a full 15, while comparators compare and subtract. The real confusion is charging versus activation: charging means a block holds redstone energy, activation means a mechanism — piston, door, trapdoor, lamp, dispenser — starts working. Charging also splits into strong and weak: torches, repeaters and comparators strongly charge blocks, dust only weakly, and only strongly charged blocks power adjacent dust. Get this layer right or you will lose half an hour to 'the block clearly has signal but nothing happens'.
The Three Basics: OR, NOT, AND
OR is trivial: merge two dust lines into one, and either input produces a 1, with no components and no added delay. NOT is a torch on a block's side: charge the block and the torch goes out, output 0; cut the input and it lights, output 1 — inherently inverting at one redstone tick. AND is 'NOT-OR-NOT': invert each input with a torch, OR the two torch outputs, and only when both inputs are 1 (both torches dark) does the merged line carry nothing — add one more NOT for a standard AND. Remember the division of labor: torches invert, dust merges.
XOR, XNOR and the Comparator
XOR outputs 1 only when the inputs differ: AND(A, NOT B) plus AND(B, NOT A), then OR the results. The torch version costs three to four ticks and real space; the piston version, where a piston slides a conductor to break a line, is compact and fast and the digital player's favorite. XNOR is XOR inverted — output 1 when inputs match. Comparators are a different class of tool: they compare two input strengths and output the stronger, subtract, and read container fill levels — sorters, item counters and brew timers all depend on them. Think of a comparator as an analog component rather than a logic gate and everything gets clearer.
Latches and Flip-Flops: Combinational to Sequential
Gates only see present inputs; remembering state needs sequential logic. The classic is the SR latch: two torches staring at each other, where a pulse on S sets the output to 1 and holds, a pulse on R resets to 0 and holds, and pulsing both is forbidden. That is 'press a button and the door stays open until another button closes it'. A T flip-flop toggles on every rising edge, turning a button press into a switch. Always add edge detection — a pulse generator — at the input, or the circuit oscillates wildly while the input stays high. A D flip-flop writes its input to output while the clock is 1, and a repeater is essentially a D flip-flop with an inverted clock.
Building a Half Adder and a Full Adder
A half adder adds two one-bit numbers and outputs two results: the sum bit from XOR (0 when equal, 1 when different) and the carry from AND (1 only when both are 1). Combine a half adder with 'accept the incoming carry' and you get a full adder: two half adders plus an OR gate handle A, B and carry-in. Chain N full adders with the carry rippling along and you have an N-bit adder — the starting point of every Minecraft calculator. Practical advice: prototype in creative on a large flat area, use levers as inputs and lamps as outputs, verify the truth table bit by bit, then compress. The joy of digital redstone is piling dumb components into correct logic; chasing compactness first only leads to debugging despair.
Comments
Powered by GitHub Discussions — sign in with GitHub to comment.