Loading simulator…
The POWER input initializes all sequential elements. When POWER = 0, the shift register, edge detectors, reset controller, and STOP flag are cleared so that the circuit always begins from a known state.
The Reset button is connected to a rising-edge detector that generates R_EDGE. This pulse clocks a T flip-flop with T = 1, causing its output RST_N to alternate between reset and normal modes.
T = 1
Clock = R_EDGE
Q = RST_NWhen RST_N = 0, the shift register and STOP flag are cleared. A separate rising-edge detector monitors RST_N and generates RST_EDGE when the circuit changes from reset mode to normal mode.
The serial input of the shift register is formed as:
SERIAL_IN = Q10 + RST_EDGE
Because every register bit is 0 during reset, RST_EDGE inserts one HIGH bit when normal operation begins. Afterward, Q10 provides feedback and the register behaves as a ring counter.
The Point button uses another rising-edge detector to generate P_EDGE. This pulse clocks a D flip-flop configured as:
D = 1
Clock = P_EDGE
CLR = RST_N
Q = STOP = OFThe first P_EDGE sets STOP and OF to 1. Further presses continue loading 1, so the result remains locked.
The ring-counter clock is controlled using:
CLK_GATE = Clock · STOP'
While STOP = 0, clock pulses reach the shift register. When STOP = 1, the clock is blocked and the selected LED remains ON.
The outputs connected to LEDs of the same color are combined to form WHITE, BLUE, RED, and YELLOW signals. The BCD inputs of Score are:
b0 = (WHITE + YELLOW) · STOP · RST_N
b1 = (BLUE + YELLOW) · STOP · RST_N
b2 = (RED + YELLOW) · STOP · RST_N
b3 = 0These equations display 1, 2, 4, or 7 only after the game stops. In reset mode or while the LED is moving, Score remains 0.