Clock

Inputs

PinTypeDescription

This element has no inputs.

Outputs

PinTypeDescription
QbitToggles between 0 and 1 on each simulation step

How It Works

The Clock is an automatic timing generator that produces a continuous square wave: 0 → 1 → 0 → 1 → …

On each simulation step, the Clock toggles its output state. This means:

In tickMode (levels 11+), you control the clock through the Clock Control panel (▶ Play / ⏸ Pause / ⏭ Single Step). The panel manages all Clock elements simultaneously and ensures coordinated timing across the entire circuit.

In non-tickMode levels, the Clock toggles automatically on each call to runStep() or the simulation solver.

Usage

The Clock is required for all sequential circuits. It is used in the following levels:

Connect the Q output to the Clock input of all sequential elements. The Clock itself has no configuration — its behavior is governed by the Clock Control panel in tickMode levels.

Go to the simulator →