Reconstruct a peripheral read from an edge log, including a wait and the return trip.
Hardware context: GPIO peripheral read path. Memory-mapped I/O diagnosis
A manager issues one word read. The lab GPIO input word sits at offset 4. This Icarus capture uses a different pin value and two wait edges.
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
| Edge | AHB request | APB phase | PREADY | HREADY | PRDATA |
|---|---|---|---|---|---|
| 5 | 0x10001004 | idle | 0 | 1 | 0x00000000 |
| 6 | idle | setup | 0 | 0 | 0x00000091 |
| 7 | idle | access | 0 | 0 | 0x00000091 |
| 8 | idle | access | 0 | 0 | 0x00000091 |
| 9 | idle | access | 1 | 1 | 0x00000091 |
GPIO starts at 0x10001000. Each row gives the signals sampled at that rising edge. The bridge returns PRDATA directly during access.
| Entry | Your decision |
|---|---|
| ISSUE | Edge where the address is accepted. |
| OFFSET | Register offset in bytes. |
| SETUP | Edge ending setup. |
| FIRST_ACCESS | First edge sampling access. |
| WAIT_EDGES | Count access edges with PREADY low. |
| ACCEPT | Edge completing the peripheral read. |
| RETURN | Edge completing the manager data phase. |
| VALUE | Returned data as a decimal number. |
| ELAPSED | Full clock periods from address acceptance to data completion. |
| PHASES | Count sampled cycles including the address cycle. |
| TRANSFERS | How many GPIO reads complete in the table? |
| LATE_EDGE | Which return edge would you see if GPIO added EXTRA_WAIT more access cycles to this trace? |
Examples
Example 1
ISSUE- Input
Edge where the address is accepted.
- Output
matches = 1
Edge 5 has a request and HREADY high.
Example 2
OFFSET- Input
Register offset in bytes.
- Output
matches = 1
Subtract the GPIO base from the requested address to get four bytes.
Example 3
SETUP- Input
Edge ending setup.
- Output
matches = 1
Edge 6 samples setup. Access follows it.
Constraints and Contract
- Keep the parameter and named constants. Use the numeric codes and units on this page.
- For LATE_EDGE, enter a constant expression using EXTRA_WAIT. Only this entry changes with the parameter. The supported integer range is 0 through 15, inclusive.
Hints
Hint 1
Find an active address phase sampled with HREADY high.
Hint 2
Mark the last access edge, then subtract the address edge to find elapsed periods.
Hint 3
Look for a row where both buses complete together.
What the grader checks: Each check compares the full eight-bit answer. Parameter trials change one condition and keep the other decisions fixed.
12 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