CodiodeCodiode
Home
Problem Solving
Skill Tracks
My Assignments
Contests
Leaderboard
Community
Settings
Codiode/Problems/Sequential Logic

BCD Decade Counter: Synchronous Reset Construction

EasyLogic CircuitBuild

Digital clocks, frequency dividers, and multi-digit displays rely on binary-coded decimal (BCD) counters to track base-10 values. The decade counter truncates a standard 4-bit binary sequence to a modulus of 10.

Implement a 4-bit synchronous BCD decade counter. On every clock cycle where rst is 0, the counter increments. It must count from 0 to 9 (binary 0000 to 1001). When the counter reaches 9, the next state must wrap around to 0. When rst is 1, the counter synchronously resets to 0000.

| rst | Current Q | Next Q | |-------|-------------|----------| | 1 | X | 0 | | 0 | 0 to 8 | Q + 1 | | 0 | 9 | 0 |

Constraints

  • Use only synchronous logic for the state updates.
  • The counter must strictly output the sequence 0 through 9 and wrap back to 0.
  • Do not use asynchronous clears to force the wrap-around.

Topics

BCDSynchronous LogicCounters

Solve this problem

Place the gates, wire them up and watch the signals settle. Every submission runs on the same simulation engine that grades it.

This problem is part of Codiode Pro. The statement above is free to read.

Sign in to solveSee what Pro unlocks

The circuit builder and code editor need a desktop screen. On a phone, read the problem here and open it on a laptop to solve.

Related problems

  • 3-bit Ripple Counter from Toggle Flip-FlopsEasy
  • D Latch from a 2:1 MUXEasy
  • 2-bit Ring CounterEasy
  • T Flip-Flop from a D Flip-FlopEasy
  • Handshake Deadlock Due to Early ResetHard
  • Reconvergence of Individually Synchronized BitsHard
  • Debug: Asynchronous Clear GlitchHard
  • Clock Gate Enable Crossing DomainsHard

Browse all problems · Learning tracks