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

Johnson Counter: 8-Phase Clock Generator

MediumLogic CircuitBuild

Multiphase clock generation is essential in phase-locked loops, stepper motor drivers, and high-speed memory interfaces. A Johnson counter paired with combinational decoding provides glitch-free, non-overlapping clock phases from a single reference clock.

Implement a 4-bit Johnson counter and decode its states to generate 8 distinct phase outputs (p0 through p7). The counter advances on the rising edge of clk. When rst is HIGH, the internal state must reset to 0000. Each phase output must be HIGH for exactly one clock cycle out of the 8-cycle sequence.

| Internal State (Q3 Q2 Q1 Q0) | Active Phase | |--------------------------------------|--------------| | 0 0 0 0 | p0 | | 0 0 0 1 | p1 | | 0 0 1 1 | p2 | | 0 1 1 1 | p3 | | 1 1 1 1 | p4 | | 1 1 1 0 | p5 | | 1 1 0 0 | p6 | | 1 0 0 0 | p7 |

Constraints

  • Use exactly four D flip-flops to build the internal counter.
  • Use exactly eight 2-input logic gates to decode the phases.
  • Ensure all phase outputs are non-overlapping.
  • Reset the counter to state 0000 when rst is HIGH.

Topics

CountersShift RegistersClock Generation

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