Set of changes to the daemon to support additional sample rates and to enhance the test suites to verify with 192Khz and 384Khz
The build script has been modified to checkout the driver branch aes67-daemon-issue11 with fixes to support sample rates higher than 192Khz. These changes fix #124 and #122
This commit is contained in:
parent
ca207e8479
commit
0dd3b9bf70
2
build.sh
2
build.sh
@ -11,7 +11,7 @@ TOPDIR=$(pwd)
|
||||
|
||||
cd 3rdparty
|
||||
if [ ! -d ravenna-alsa-lkm ]; then
|
||||
git clone --single-branch --branch aes67-daemon https://github.com/bondagit/ravenna-alsa-lkm.git
|
||||
git clone --single-branch --branch aes67-daemon-issue11 https://github.com/bondagit/ravenna-alsa-lkm.git
|
||||
cd ravenna-alsa-lkm/driver
|
||||
make
|
||||
cd ../..
|
||||
|
@ -13,9 +13,9 @@ function cleanup {
|
||||
}
|
||||
|
||||
function usage {
|
||||
echo 'Usage run_latenvy_test.sh sample_format sample_rate channels duration frames' >&2
|
||||
echo 'Usage run_latency_test.sh sample_format sample_rate channels duration frames' >&2
|
||||
echo ' sample_format can be one of S16_LE, S24_3LE, S32_LE' >&2
|
||||
echo ' sample_rate can be one of 44100, 48000, 96000' >&2
|
||||
echo ' sample_rate can be one of 44100, 48000, 96000, 192000, 384000' >&2
|
||||
echo ' channels can be one of 2, 4, 6, up to 64' >&2
|
||||
echo ' duration in seconds' >&2
|
||||
echo ' frames buffer size in frames' >&2
|
||||
@ -85,6 +85,10 @@ elif [ $SAMPLE_RATE == "48000" ]; then
|
||||
PTIME="1"
|
||||
elif [ $SAMPLE_RATE == "96000" ]; then
|
||||
PTIME="0.5"
|
||||
elif [ $SAMPLE_RATE == "192000" ]; then
|
||||
PTIME="0.25"
|
||||
elif [ $SAMPLE_RATE == "384000" ]; then
|
||||
PTIME="0.125"
|
||||
else
|
||||
usage
|
||||
fi
|
||||
|
@ -45,7 +45,7 @@ echo 'Creating test file ...' >&2
|
||||
if ! ./createtest $1 $2 $3 $4 ; then
|
||||
echo 'Usage run_test.sh sample_format sample_rate channels duration' >&2
|
||||
echo ' sample_format can be one of S16_LE, S24_3LE, S32_LE' >&2
|
||||
echo ' sample_rate can be one of 44100, 48000, 96000' >&2
|
||||
echo ' sample_rate can be one of 44100, 48000, 96000, 192000, 384000' >&2
|
||||
echo ' channels can be one of 2, 4, 6, up to 64' >&2
|
||||
echo ' duration is in the range 1 to 10 minutes' >&2
|
||||
exit 1
|
||||
@ -74,6 +74,10 @@ elif [ $SAMPLE_RATE == "48000" ]; then
|
||||
PTIME="1"
|
||||
elif [ $SAMPLE_RATE == "96000" ]; then
|
||||
PTIME="0.5"
|
||||
elif [ $SAMPLE_RATE == "192000" ]; then
|
||||
PTIME="0.25"
|
||||
elif [ $SAMPLE_RATE == "384000" ]; then
|
||||
PTIME="0.125"
|
||||
fi
|
||||
|
||||
SOURCE=$(cat <<-END
|
||||
|
@ -25,7 +25,7 @@ int main(int argc, char* argv[])
|
||||
}
|
||||
|
||||
int rate(atoi(argv[2]));
|
||||
if (rate != 44100 && rate != 48000 && rate != 96000) {
|
||||
if (rate != 44100 && rate != 48000 && rate != 96000 && rate != 192000 && rate != 384000) {
|
||||
cerr << "Unsupported rate " << rate << endl;
|
||||
exit(1);
|
||||
}
|
||||
|
@ -4,7 +4,7 @@
|
||||
"http_base_dir": "./webui/dist",
|
||||
"log_severity": 3,
|
||||
"playout_delay": 0,
|
||||
"tic_frame_size_at_1fs": 64,
|
||||
"tic_frame_size_at_1fs": 48,
|
||||
"max_tic_frame_size": 1024,
|
||||
"sample_rate": 48000,
|
||||
"rtp_mcast_base": "239.1.0.1",
|
||||
|
@ -583,7 +583,7 @@ int main(int argc, char *argv[])
|
||||
break;
|
||||
case 'r':
|
||||
err = atoi(optarg);
|
||||
rate = err >= 4000 && err < 200000 ? err : 44100;
|
||||
rate = err >= 4000 && err < 400000 ? err : 44100;
|
||||
break;
|
||||
case 'B':
|
||||
err = atoi(optarg);
|
||||
@ -624,7 +624,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
loop_limit = loop_sec * rate;
|
||||
latency = latency_min - 4;
|
||||
buffer = (char*)malloc((latency_max * 2 * snd_pcm_format_width(format) / 8) * channels);
|
||||
buffer = (char*)malloc((latency_max * 4 * snd_pcm_format_width(format) / 8) * channels);
|
||||
|
||||
setscheduler();
|
||||
|
||||
|
@ -186,6 +186,8 @@ class Config extends Component {
|
||||
<option value="44100">44.1 kHz</option>
|
||||
<option value="48000">48 kHz</option>
|
||||
<option value="96000">96 kHz</option>
|
||||
<option value="192000">192 kHz</option>
|
||||
<option value="384000">384 kHz</option>
|
||||
</select>
|
||||
</th>
|
||||
</tr>
|
||||
|
Loading…
x
Reference in New Issue
Block a user