How to Build a Digital Clock in Logisim-evolution

A digital clock is the perfect second project after your first logic-gate circuit. It uses three components you will meet in almost every later design: the Clock, the Counter, and the Comparator. By the end of this tutorial you will have a six-digit clock counting real seconds, minutes, and hours.

If you have not installed the simulator yet, grab it from the download page first (version 5.0.0, free and open-source).

What you will use

All of these live in the component tree on the left side of the window:

  • Clock — Wiring library. Generates the tick that drives everything.
  • Counter — Memory library. Counts up by one on every clock tick.
  • Comparator — Arithmetic library. Tells you when the count reaches a limit.
  • Constant — Wiring library. Holds the limit value (10, 6, 24 …).
  • Hex Digit Display — Input/Output library. Shows each digit.

Step 1 — Place a clock and a ones counter

  1. Start a new project: File → New.
  2. From the Wiring library, place a Clock on the canvas.
  3. From the Memory library, place a Counter. In its attributes (bottom-left pane), set Data Bits to 4.
  4. Wire the Clock output into the Counter’s clock input — the pin marked with a small triangle.
  5. Enable ticking: Simulate → Ticks Enabled. While building, open Simulate → Auto-Tick Frequency and pick a fast rate (e.g. 8 Hz) so you can see the counter run.

The counter now counts 0 to 15 and wraps around. A clock digit needs 0 to 9, so we have to stop it at 10.

Step 2 — Reset the counter at 10 with a Comparator

  1. From the Arithmetic library, place a Comparator and set its Data Bits to 4.
  2. Wire the Counter output into the Comparator’s A input.
  3. Place a Constant (Wiring library), set its Value to 0xA (hex for 10), and wire it into the Comparator’s B input.
  4. The Comparator has three 1-bit outputs: >, =, <. Wire the = output back into the Counter’s clear input.
  5. Add a Hex Digit Display and wire the Counter output into it.

The moment the counter reaches 10, the Comparator’s = output goes high and clears the counter. The digit now cycles 0–9 forever. That short = pulse is also useful: it is the carry into the next digit.

Step 3 — Chain the digits: tens, minutes, hours

Every higher digit is just another copy of the same pattern, clocked by the carry of the digit below it:

  • Seconds tens (0–5): new Counter, clocked by the seconds-ones = pulse. Comparator against constant 6, = wired to clear.
  • Minutes ones (0–9): clocked by the seconds-tens carry. Reset at 10, same as Step 2.
  • Minutes tens (0–5): clocked by the minutes-ones carry. Reset at 6.
  • Hours (00–23): two counters. Detect 24 with two Comparators — one checking tens = 2, one checking ones = 4 — feed both = outputs into an AND gate, and use the AND output to clear both hour counters.

Give each digit its own Hex Digit Display. If the wiring starts to look like spaghetti, read Tunnels and Splitters: Clean Wiring — tunnels were made for exactly this kind of carry chain.

Step 4 — Slow it down to real seconds

With the Clock’s High and Low Duration at 1 tick each, one full clock cycle takes 2 ticks, and the counter advances on the rising edge — once per 2 ticks. So open Simulate → Auto-Tick Frequency and choose 2 Hz: each count now lands exactly one second apart, and you have a real clock.

Troubleshooting

  • Counter never counts: check Simulate → Ticks Enabled is on, and that the clock wire lands on the triangle-marked clock pin, not a data pin.
  • Digit counts past 9: you wired the wrong Comparator output. It must be =, not >.
  • Carry never fires: the = pulse lasts a single tick — that is normal and long enough for both clear and the next counter’s clock.
  • Everything frozen after edits: Simulate → Reset Simulation (Ctrl+R) returns the circuit to its power-on state.

Go further

Open Simulate → Chronogram and record the carry chain to watch the ripple move through the digits — the Chronogram & Timing Analysis tutorial shows how. When this feels easy, the next step up is Building a Simple CPU, where counters become program counters and state machines.