wirenerd
← All Build Guides
Build Guide · Motor Control

Counter

Press a button three times to turn on a light — then wire a reset. The exact circuit to learn how counters behave.

Difficulty: IntermediateBuilds on: a simple input circuitLesson: read the theory →

What you’re building

L1L2/NCA1RSTBTNRSTA2C
Button (with actuator cap) pulses the counter at A1; a reset switch ties to RST; A2 returns to L2/N. The counter's contact turns on the light at the target count.

Parts to add

  • 1Power Source
  • 1Push Button NO
  • 1Counter
  • 1NO Contact
  • 1Light
  • 1Single-Pole Switch (reset)

Steps

  1. Add the parts

    Click Power Source, Push Button NO, Counter, NO Contact, Light, and a Single-Pole Switch (for reset). Spread them out.

  2. Set up the counter

    Click the Counter. When prompted, type a number for the target count (e.g. 3), then click it again and type a letter (e.g. C). Click the NO Contact and type C so it follows the counter’s output.

  3. Wire the count input

    To wire, click the first terminal (it highlights), then click the second — a wire connects them. Click empty space to deselect. The counter’s A1 and A2 are its input; each pulse on A1 adds one to the count.

    Power Source L1 → Push Button (left)
    Push Button (right) → Counter A1
    Counter A2 → Power Source N
  4. Wire the reset

    Wire a switch to the counter’s RST terminal. Energizing RST clears the count back to zero.

    Power Source L1 → Reset Switch (left)
    Reset Switch (right) → Counter RST
  5. Wire the output circuit

    When the count reaches the target, the counter energizes its letter C, closing the C contact and lighting the lamp.

    Power Source L1 → C NO Contact (left)
    C NO Contact (right) → Light (left)
    Light (right) → Power Source N
  6. Energize and count

    Click Energize. Press the push button and watch the counter climb: 1/3, 2/3, 3/3. On the third press the light comes on. Flip the reset switch to clear it back to 0.

  7. Remember: edge-triggered

    Holding the button down only counts once. The counter counts the moment the input turns on (the rising edge), so you must release and press again for each count.

✓ Test it

  • Press the button 3 times: on the 3rd press the light comes on.
  • Flip the reset switch: count clears to 0, light goes off.
  • Hold the button down — it only counts ONCE. Counters are edge-triggered: release and press again to count.
Tip: Pair a counter with a timer for batching: count parts, then time a sealing cycle. That is real automation.

Open the Sandbox and build it

Follow the steps above with the trainer open in another tab.

Open the Sandbox →PLC Sandbox