Codiode

Maximum Pulse Width Timeout

MediumLogic CircuitBuild

Communication buses often rely on shared lines that can be pulled low by any device. If a node fails and holds the line low indefinitely, the entire bus hangs unless a watchdog timer detects the timeout and triggers a reset.

The circuit monitors a single input sig_in. When sig_in is high, the system is idle and the err_flag output remains 0. If sig_in drops low and remains low for more than 15 consecutive clock cycles, err_flag must assert high on the 16th cycle. The err_flag must immediately deassert to 0 on the next clock cycle where sig_in returns high.

Constraints

  • Use sequential logic elements to track the elapsed cycles.
  • Prevent the internal counter from wrapping around to zero if sig_in remains low indefinitely.
  • Reset the internal counter synchronously whenever sig_in is high.

Topics

countererror-detectionstate-machinetimeout

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.

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.

Part of Interface and Communication Circuits

Problem 20 of 79 in the Interface and Communication Circuits track.

Related problems

Browse all problems · Digital logic design practice problems · Learning tracks

Solve this on a laptopSend yourself the link and continue there.