Technician tool v0.4

Imported from the Google Drive folder 004-technician_tool/v0.4.
This commit is contained in:
kkallas committed 2026-09-26 17:26:00 +02:00
1 parent e161941672
commit 72adfe1cec
19 files changed
+1818 -602

No files matched your search

+17 -4
View File
@@ -182,17 +182,30 @@ def test_reset_action_failure_is_shown(rig):
assert "connect" in runner.view().note.lower()
def test_mic_disabled_switch_on_verified(rig):
def test_mic_switch_flip_verified_without_restart(rig):
engine, runner, clock, actions, board, _ = rig
_bench(engine)
runner.start("mic")
assert runner.step.id == "switch"
runner.answer("0") # set it to ON
assert actions == ["reset"]
board(*BOOT, "I (20000) MICROPHONE: Read 300000 bytes in 4936 ms")
assert "above the power switch" in runner.view().text
runner.answer("0") # flipped the external switch
assert actions == [] # the firmware re-reads it; no reset
board("I (95000) MICROPHONE: Read 300000 bytes in 4936 ms")
assert runner.end.id == "mic_on"
def test_mic_switch_no_effect_in_both_positions(rig):
engine, runner, clock, actions, board, _ = rig
_bench(engine)
runner.start("mic")
runner.answer("0")
board("W (95000) MICROPHONE: Microphone is in shutdown state, skipping sample collection")
assert runner.step.id == "flip_back"
runner.answer("0")
board("W (105000) MICROPHONE: Microphone is in shutdown state, skipping sample collection")
assert runner.end.id == "mic_switch_faulty"
def test_mic_clap_test_detects_dead_mic(rig):
engine, runner, clock, _, board, _ = rig
board(*BOOT, *["I (20036) MICROPHONE: Sum SQ: 0.000000, RMS pressure: 0.000000, "