Lesson 01 / 08 · Guided exploration

Start with a number that needs memory

Decide what the circuit must do before deciding how it will be built.

A counter remembers a number and updates it when allowed.Practice 1 / 4

Start with the behavior. Four binary digits can represent the numbers 0 through 15.

Make the number change

Predict: Starting at zero, what should two update events produce?

Try: In the counter below, click Start over, then Step clock twice.

Our running example · try it here

A four-bit event counter

Imagine a scoreboard that remembers a number from 0 to 15. Use the controls here before looking at the code.

Current number—0 clock edges tried
Xbit 3
Xbit 2
Xbit 1
Xbit 0

Step clock creates one update event: a rising clock edge, when the signal goes from 0 to 1.

Enable means permission to count. On: add one at the next edge. Off: keep the number even when the clock steps.

Reset requests zero at the next edge. It takes priority over Enable. Switching it on alone does not clear the number.

Start over restarts the experiment at zero, with Enable on and Reset off.

Preparing the counter…

Store

A register remembers the current number.

Calculate

Logic works out the next number.

Update

A rising clock edge lets the register accept it.

Behavior

Enable on: count once per rising edge. Enable off: keep the number. After 15 comes 0.

State

Four bits store the number. Reset sets it to zero at the next edge, regardless of Enable.

Timing goal

The later timing model allows 2 nanoseconds between edges. A nanosecond is one billionth of a second.

Implementation

Choose physical components (cells), give them locations, then build the clock and signal wires.

The RTL view shows the code and circuit for the same live counter state.

The path to a physical chip

Iterate to close constraints

Verification accompanies the flow. Failed timing, geometry, or connectivity checks can send us back to an earlier stage.

←→ lessons ·Space step clock ·P presentHDL simulation · conceptual physical models

This demo records sampled lesson visits and approximate network locations for 30 days. No raw IP or HDL is saved. Visitor privacy