Wizard Toolbox Tool map Feedback
BETAStill being built. Things may break. Tell us

Logic Studio

Drop a Logic Studio file here

A .json saved from Logic Studio, with its chips · click to choose

Logic Studio

Start with two gates, AND and NOT. Wire them up, pack what you make into a chip of your own, and build bigger chips from that, from OR and XOR up to adders and memory.

How to use it

Press Start blank for an empty board. The parts sit down the left in coloured groups: Inputs, Outputs, More inputs, More outputs, Gates, Wiring and Your chips. Click a group to jump to it, or type in Find a part. Drag a part onto the board (a see-through copy shows where it will land), or click it and then click the board. Input is a switch: click it to turn it on and off. Output is a light.

Inputs and outputs

As with gates, the parts start few and you build the rest. To bring things in there is an Input (a switch that becomes a pin when the board is a chip), a Switch (click it on and off, or set it to spring back like a button, with any keyboard key if you like, arrows and Space included), a Clock that ticks at any speed from a tick every few minutes to a million a second (past what a frame can work out, the circuit runs slower rather than skip ticks), Noise, a truly random bit, and a Pointer pad that gives where the pointer is over it as x and y bits. To send things out there is an Output (a light that becomes a pin), a Light in any colour, round, a bar either way or a square pixel, and a Speaker that plays what its wire does: a wire turning on 440 times a second sounds A4. Lights and Switches inside a chip show on the chip's face where you put them, so seven bar Lights make a 7-segment display and a grid of squares a screen. A Bus join gathers up to 64 wires into one thick wire and a Bus split spreads it out again, and a Graph draws wires over time, like a logic analyser. Select a part to set it.

More inputs and outputs

Beside the starting set, More inputs and More outputs hold parts that do bigger jobs in one go: a Number as bits, a Switch row, a Pulse per press, Random bits, a Keyboard that gives the character code of what you type, Always on; and a decimal Display, 7-segment, Hex digit, Light bar, Colour light, a Pixel screen of any width and height up to 256 by 256, in one colour or eight, with its x pins along the top and y pins down the side, a Terminal that types characters, a Buzzer and a Synth that plays the note its pins give, with volume and wave pins. Power on is on for a moment when the circuit starts, to reset flip-flops, which wake up holding whatever their gates fall into, and a Label puts words on the board or on a chip's face. A Light can have a second colour with its own input, or hide when off, and a Pointer pad can be any size and see-through, to lay over Lights on a chip's face as a touch screen. A Switch or Pulse can answer to several keys and show your own text, a Display's number can be any size, a Label can light up from a wire, and any part inside a chip can be kept off its face and still work. Keys pressed quickly reach the circuit one at a time, in the order you pressed them. Every part has its settings: select it to set sizes, speeds, colours, sounds and more.

Wiring

Drag from a pin towards another and let go: the wire jumps to the nearest pin it can join, an output (right side) to an input (left side). An output can feed any number of inputs; an input takes one wire, so a new one replaces the old. Drag a wire's end off an input to move it, or let go on empty board to remove it. A wire lights up when it carries a 1. To remove parts, drag them off the board (back onto the parts, say) and let go, or select them and press Delete or the bin at the top. Right-click a part, a wire or the board for a menu: rename, edit a chip, duplicate, delete. Drag the empty board to move round, Shift-drag to select a box of parts, and zoom with the wheel or a pinch.

Making chips

Name the board under Make a chip and press Make chip: the board becomes one part in the bar, with a pin for each input and output, in order from top to bottom, and the board is cleared for the next one. Only Inputs and Outputs become pins. The rest keep working inside the chip: a Clock keeps ticking, a Number gives the value it was left at, and Buttons and displays show on the chip's face, smaller, laid out as they were, where a Button can still be pressed. AND then NOT is NAND; NOT on both inputs of an AND, then NOT again, is OR; OR then NOT is NOR. When the board does what a common gate does (NOT, AND, OR, NAND, NOR, XOR or XNOR, with any number of inputs), the panel says so and offers its name. To make a chip of part of the board, select those parts (Shift-drag a box) and press Make chip of selection, or right-click them: wires coming in become its inputs, wires going out its outputs, and the chip takes their place on the board, wired as before. Every chip can go inside the next, so a few steps take you from two gates to an adder. Edit under Your chips opens a chip on the board to change it; every place it is used changes with it.

Truth table

The panel lists what the outputs settle to for every mix of inputs, worked out from everything off, for boards with up to 10 inputs. A circuit with memory, such as a latch, keeps what it had, so its table shows only one way it can fall.

Saving

Save writes a .json file with the board and every chip, to open here again later (drop it on the start screen). Nothing is kept in the page, and the page warns you before you leave with changes not saved.

Questions

Why only AND and NOT?

Together they can make every other gate. AND and OR alone cannot, as neither can turn a 1 into a 0. Starting from AND and NOT, you build NAND, OR, NOR and XOR yourself, then adders and memory, the way a real computer is built up. (NAND alone, or NOR alone, could make everything too, but they are harder to follow at first.)

How does the simulation work?

Each chip comes down to AND and NOT gates in the end. They are worked out over and over until nothing changes, so signals ripple through and loops behave like real gates: a latch holds its bit, and a ring with an odd number of NOTs in it keeps flipping.

Can I put a chip inside itself?

No. A chip can hold any chip made before it, but not itself or a chip that holds it.

Is anything uploaded?

No. It all runs in this page, on your device, and nothing is sent anywhere.

Your circuits stay on your device · nothing is uploaded