Week 4 · Lesson 2 · 55 minutes
Handle unknown and disconnected states
Build and explain this stage of your own connected prototype.
Planned lesson. Follow your teacher’s teaching order.
Task steps and checks
Do the work
- Choose a fault rule that fits your user. The example expires manual reports after 60 seconds and resets to Unknown. Choose and explain your own limit or rule.
- Predict and test expiry without a new report, reset, invalid input, browser disconnection and reconnection. A page reading /state is not a new report. Without approved access, mark the link tests NOT TESTED.
- Example: a browser loses contact while the board keeps flashing. The page says “Not confirmed”; it must not claim that the board stopped. Reconnect and read again.
- No new report
- Board may expire it • No browser reply
- Page shows unconfirmed
Check your result: Compare each expected board and page outcome against actual behaviour. Fix one difference you can reproduce and check it again.
Revised weekly handout pages: 1, 2.
Materials
Existing October design, saved code, teacher-verified ESP32 circuit, USB data cable and computer; shared hardware, individual evidence.
Resources
Vocabulary
- State transition
- A rule linking the current state and an event to the next state and output.
More examples and practice
Retrieve your saved version · 5 minutes
Open your own latest code and evidence. State what actually works and the next check; keep earlier versions.
Handle unknown and disconnected states · 10 minutes
A stale report and a broken browser connection are different faults. The demo expires manual reports after 60 seconds and starts unknown after reset. A failed page request marks the page unknown; it does not prove the board stopped. Choose fault rules that fit your user.
Does reading /state every second keep a manual report fresh?
Reveal reasoning
No. Reading is not a new observation. Only a valid new report refreshes confirmedAt; otherwise the information should expire under the demo rule.
Build test and record · 30 minutes
Work through the task below. Take turns with hardware; each student records their own actions, predictions and observations.
Practice
- Test expiry without sending a new report, reset, invalid input, browser disconnection and reconnection. Predict first. Record actual behaviour and fix one discrepancy. Justify your expiry time or a different appropriate fault rule.
Save and explain your evidence · 10 minutes
Save the version and results. Explain one decision and one limitation to a partner. Record unfinished work for the next lesson instead of claiming success.
Keep flashing responsive / Handle unknown and disconnected states
Do only the parts you did not finish in class. Write what really happened; if you did not test something, write NOT TESTED. This is one task for the week, and nothing else is due.
- Open this week’s handout and your saved code.
- Finish the evidence for both lessons. Use only your saved code and real results.
You are finished when: The evidence for both lessons is complete and matches what you really did.
Why this matters: Each week’s evidence becomes part of the connected prototype evidence you submit in Week 8.
- There is no hardware task at home.
Revised weekly handout pages: 1, 2.
Weekly homework (Word) · Chinese weekly handout (Word)
Feedback on this week’s evidence
Task feedback only. Final C and D are separate best-fit judgements out of 8 using the school’s current MYP Year 5 criteria; do not average weekly bands.
- This week’s task
- Keep flashing responsive / Handle unknown and disconnected states
- Personal evidence and explanation
- Identify your own technical action, evidence file, actual outcome and limitation.
| Band | Observable evidence |
|---|---|
| 0 | No assessable evidence for this task yet. |
| 1–2 | Identifies parts of the task; personal work and results are difficult to follow. |
| 3–4 | Completes some steps with support; evidence or explanations have gaps. |
| 5–6 | Completes the task with traceable personal evidence and explains results and limitations. |
| 7–8 | Works independently, uses precise evidence to justify decisions and checks the effect of changes. |