Audio drop-outs or “stutters”
The symptom is audio is sounding like it’s skipping some frames.
For a sample audio, play this stutter.wav file 1. Hear the stutters at 2.5, 3.8, and 8.8 second.
Check by looping back microphone to speaker: check whether the symptom is observable when looping the microphone to the speaker locally.
Check for dangling call in PBX. A dangling call is call that is left active in the PBX because previous (pjsua) application has terminated abruptly.
Try to enlarge
PJMEDIA_SOUND_BUFFER_COUNTvalue by setting it in your config_site.h. Increase it to, say, 16, and see if it fixes the problem. But be aware that enlarging this buffer will increase the audio latency, so find a minimum value where the sound quality doesn’t break.
audio file courtesy of Chen Huan <chenhuan at sict.ac.cn> who managed to convince his girlfriend to record the audio for testing :)