Two changes that together address the user-reported 'speaker selector
not working' AND 'audio quality bad' symptoms on iPhone:
1. AppDelegate.swift: AVAudioSession mode .voiceChat -> .default
.voiceChat binds the underlying AudioUnit's output element to a
SINGLE physical transducer (the receiver/earpiece) at session-
configure time. overrideOutputAudioPort updates AVAudioSession's
route metadata so currentRoute.outputs reports Speaker, but the
AudioUnit's output binding is stale and audio keeps routing to
the original transducer. Net: tapping Speaker in the picker
flipped the route in our log but produced no audible change.
.voiceChat also enables iOS's telephony processing chain (forced
mono output, aggressive AGC, heavy noise gating) which explains
the 'garbled / watery / metallic' quality complaints.
.default mode uses iOS's standard audio graph: stereo output, no
AGC, no telephony post-processing, AudioUnit re-binds live when
the route changes. Same mode Music.app and most non-telephony
apps use. Trade-off: we lose iOS hardware AEC. If users report
speakerphone echo we'll add software AEC (DEC-030).
Category options unchanged \u2014 .allowBluetoothHFP +
.allowBluetoothA2DP still permit BT headsets in both directions.
2. engine.rs::build_output_stream: mono device downmix fix
The mixing path at dev_channels==1 previously wrote only the L
channel of AudioHandler's stereo output into the single mono
device channel and discarded R entirely. Anything panned right
in the stereo voice mix was silently lost \u2014 on .voiceChat
speakerphone (forced mono device) this manifested as quiet
remote speakers being inaudible. Fix: when dev_channels==1,
output = (L + R) * 0.5 instead of just L. The dev_channels>=2
branch is unchanged.
With change #1 iOS will typically expose stereo so this branch
is rarely hit, but the fix is correct for any genuinely-mono
sink (some BT car-audio profiles, USB mono headsets).