Put an interrupted timer service back in order from the evidence at each boundary.
Hardware context: External interrupt service path. Interrupt handler bring-up
A recorder lost its timestamps. The nine tickets below belong to one timer event. Number the stages from 1 through 9. Use this exercise schedule.
This worksheet uses named constants. The first three entries show how to record your decisions.
Signals in the Timeline
| Signal | Width | Role |
|---|---|---|
question | 8 | input of each check |
Full specification
The device starts masked. It records the match before firmware unmasks it. The gateway then latches the request.
The core enters before the handler reads its claim word. The handler records the time, clears the device, completes the claim and returns.
| Entry | Your decision |
|---|---|
| MATCH | Timer remembers a compare match. |
| UNMASK | Firmware opens the timer mask. |
| QUEUE | External controller records the request. |
| COMPLETE | Handler releases the claim. |
| RESUME | Interrupted work continues. |
| CLAIM | Handler reads the source number. |
| CLEAR | Peripheral accepts the clear. |
| ENTER | Core transfers control to its handler. |
| RECORD | Handler saves the service timestamp. |
| RETURN_EDGE | On a separate clock trace the return edge is 14 with zero waits. Which edge sees return with WAIT extra clear-access cycles? |
Examples
Example 1
MATCH- Input
Timer remembers a compare match.
- Output
matches = 1
The match starts this service.
Example 2
UNMASK- Input
Firmware opens the timer mask.
- Output
matches = 1
The match was already recorded when firmware opened the mask.
Example 3
QUEUE- Input
External controller records the request.
- Output
matches = 1
The controller now sees the device request.
Constraints and Contract
- Keep the parameter and named constants. Use the numeric codes and units on this page.
- For RETURN_EDGE, enter a constant expression using WAIT. Only this entry changes with the parameter. The supported integer range is 0 through 7, inclusive.
Hints
Hint 1
Find the first block that remembers the event.
Hint 2
Separate a device write from a controller transaction.
Hint 3
Place the extra cycles before completion.
What the grader checks: Each check compares the full eight-bit answer. Parameter trials change one condition and keep the other decisions fixed.
10 checks on Icarus Verilog · server. Run the examples first, then check the full regression. Full checks use the server judge. Downloads contain your source only; samples require the simulation service. A passing result establishes the tested cases, not a proof for all possible inputs.
See all 2 problems on this path