logigate/app/lib/logic
Fabian @ Blax Software e55bd47310 A memory that stays: circuits keep their bits across visits and saves; Power off and on
What latches, flip-flops, registers and RAM built from NANDs hold is no
longer lost when you go into a component and come back, reload the page or
open the project on another computer. Leaving a circuit puts its bits in
the project, and opening it starts from them.

Only the gates on feedback loops can hold a bit, so only those that are 1
are kept, plus the clocks that are high: each node id once, each gate as
the path levels it shares with the gate before plus the rest. 1,024
flip-flops take about 30 KB. Restoring runs the gates in the order signals
flow, so the gates in front of a latch are right before it reads them;
gates that no longer exist after an edit are ignored.

The bits go with every save, file, share link and account upload. Between
saves (a clock running, a button pressed) they are put in this browser's
copy every 30 seconds and when the page is left, without counting as a
change: no sync, savegame or undo step of their own, and never over a save
made in another tab. Projects without them start from all zeros as before.

"Power off and on" in the menu on the circuit's name, or with Space,
starts the open circuit again from all zeros.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-26 18:09:18 +01:00
..
analyze.ts BF inverted inputs: lamps and outputs show the inverted value, and checks read it 2026-10-23 12:27:12 +02:00
bulk.ts A output panels, and switches, buttons, clocks or lamps combined into one panel 2026-10-21 14:38:59 +02:00
cables.ts A cable straight off a component's pins: from its outputs or into its inputs, in groups like S0–S3 2026-10-21 14:13:24 +02:00
challenges.ts A logigate: NAND-only logic editor and simulator with components, challenges and examples 2026-10-17 12:49:38 +02:00
check.ts A output panels, and switches, buttons, clocks or lamps combined into one panel 2026-10-21 14:38:59 +02:00
compile.ts BF inverted inputs: lamps and outputs show the inverted value, and checks read it 2026-10-23 12:27:12 +02:00
examples.ts A transistor counts and records, cables, pixels and screens 2026-10-20 19:29:16 +02:00
fit.ts A connector types of your own: HDMI, RJ45 or any bus, with out and in ports and one cable that carries every line both ways 2026-10-22 18:59:56 +02:00
geometry.ts A connector types of your own: HDMI, RJ45 or any bus, with out and in ports and one cable that carries every line both ways 2026-10-22 18:59:56 +02:00
labels.ts A output panels, and switches, buttons, clocks or lamps combined into one panel 2026-10-21 14:38:59 +02:00
latch.ts A latch parts onto each other: pins touching, no wires, moving together 2026-10-23 15:34:36 +02:00
ops.ts A latch parts onto each other: pins touching, no wires, moving together 2026-10-23 15:34:36 +02:00
panels.ts R panel rows editor: drag to reorder, add above or below, gaps you can see, no folded settings 2026-10-23 12:59:16 +02:00
progress.ts A connector types of your own: HDMI, RJ45 or any bus, with out and in ports and one cable that carries every line both ways 2026-10-22 18:59:56 +02:00
project.ts A memory that stays: circuits keep their bits across visits and saves; Power off and on 2026-10-26 18:09:18 +01:00
puzzles.ts BF inverted inputs: lamps and outputs show the inverted value, and checks read it 2026-10-23 12:27:12 +02:00
routing.ts A latch parts onto each other: pins touching, no wires, moving together 2026-10-23 15:34:36 +02:00
search.ts A Loxone-style working aids: named signals, inverted inputs, a project check, values on cables, search, printable sheets; wire ends move by dragging 2026-10-21 13:26:59 +02:00
sim.ts A memory that stays: circuits keep their bits across visits and saves; Power off and on 2026-10-26 18:09:18 +01:00
state.ts A memory that stays: circuits keep their bits across visits and saves; Power off and on 2026-10-26 18:09:18 +01:00
storage.ts A main menu: free play, campaign, challenges and leaderboard over a circuit that builds itself 2026-10-22 12:22:35 +02:00
types.ts A memory that stays: circuits keep their bits across visits and saves; Power off and on 2026-10-26 18:09:18 +01:00
wide.ts BF inverted inputs: lamps and outputs show the inverted value, and checks read it 2026-10-23 12:27:12 +02:00
wires.ts A Loxone-style working aids: named signals, inverted inputs, a project check, values on cables, search, printable sheets; wire ends move by dragging 2026-10-21 13:26:59 +02:00