Distributed Audiometric Test — Working Prototype (Cross-Device)

Device A plays a pure test tone. Device B listens to the room via FFT and streams ambient-noise data to Device A in real time. If ambient energy in the test-tone band crosses the threshold, Device A auto-pauses. This version connects over a WebSocket relay, so Device A and Device B can be two separate phones, on two separate networks, on two separate sides of the room.

Connection

Both devices must enter the same relay server URL and the same session code, then tap Connect before starting their side.

Not connected.
Device A · Primary Test Node

Plays the test tone

Select a frequency and start. This tab plays the tone through your speakers/headphones and watches for pause signals from Device B.

Idle — waiting to start.
Device B · Ambient Monitor

Listens to the room

Grants mic access, runs a live FFT, and streams the decibel level of the test band to Device A roughly every 50ms.

Test band level
— dB
Idle — mic not started.
What this demonstrates: the core claim — a physically decoupled second device performing continuous FFT-based ambient monitoring and gating a first device's test playback — running with real microphone input and real audio output on two independent physical devices, connected over a real network link (WebSocket), not a same-browser simulation.

How to use it: host this file over HTTPS (required for mic access on mobile), run the relay-server.js somewhere reachable, enter its wss:// URL and a shared session code on both phones, tap Connect on each, then Start on Device A and Start monitoring on Device B.