Skip to content

audio/alsa_record_playback_automated uses a painful 5035 Hz tone — all other playback tests in the same provider use 512 Hz #2633

Description

@pyma1

Bug Description

pipewire_test.py and audio_test.py hardcode DEFAULT_TEST_FREQUENCY = 5035 — a 5 kHz pure sine wave at 70% volume for 30 seconds.

5 kHz is in the peak sensitivity range of human hearing (ISO 226). The tone is piercing, causes physical discomfort, and is audible through closed doors — heard by people outside the testing room who never consented to the exposure.

Every other playback test in this provider (audio/playback_auto, audio/playback_headphones, audio/playback_hdmi, etc.) correctly uses freq=512. The comment says 5035 was chosen because it's "high enough to be reliable" — but 512 Hz works fine in all the manual tests through identical GStreamer pipelines. There is no technical justification for the painful frequency.

Fix: Change DEFAULT_TEST_FREQUENCY from 5035 to 512 in both pipewire_test.py and audio_test.py. Lower PLAY_VOLUME from 70 to 30-40. Add try/finally to restore volume on abort.

References: ISO 226:2023 (ear most sensitive 2-5 kHz), Hyperphysics (ear canal resonance 2-5 kHz), Lawton ISVR TR334 (75 dB limit at 6.3 kHz to avoid subjective effects), Fletcher et al. JASA 2018 (high-frequency tones cause discomfort/pain).

Cert-blocker Test Case

  • cert-blocker

To Reproduce

General full test with audio.

Expected Result

lower freq and volume.

Actual Result

lower freq and make more comfortable for human.

Environment

It's the checkbox issue itself. no os related.

Relevant log output

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions