for more than one CPU core use higher audio quality

This commit is contained in:
Volker Fischer 2019-10-01 16:50:47 +02:00
parent dc2ef0fbb4
commit 3c49eb9654

View file

@ -85,9 +85,15 @@ echo "Using USB audio device: ${ADEVICE}"
# write Jamulus ini file for setting the client name and buffer settings
JAMULUSINIFILE="Jamulus.ini"
NAME64=$(echo "Raspi $(hostname)"|cut -c -15|tr -d $'\n'|base64)
if [ "$NCORES" -gt "1" ]; then
echo -e "<client>\n <name_base64>${NAME64}</name_base64>" > ${JAMULUSINIFILE}
echo -e " <autojitbuf>1</autojitbuf>\n <jitbuf>3</jitbuf>\n <jitbufserver>3</jitbufserver>" >> ${JAMULUSINIFILE}
echo -e " <audiochannels>2</audiochannels>\n <audioquality>1</audioquality>\n</client>" >> ${JAMULUSINIFILE}
else
echo -e "<client>\n <name_base64>${NAME64}</name_base64>" > ${JAMULUSINIFILE}
echo -e " <autojitbuf>1</autojitbuf>\n <jitbuf>3</jitbuf>\n <jitbufserver>3</jitbufserver>" >> ${JAMULUSINIFILE}
echo -e " <audiochannels>0</audiochannels>\n <audioquality>0</audioquality>\n</client>" >> ${JAMULUSINIFILE}
fi
# taken from "Raspberry Pi and realtime, low-latency audio" homepage at wiki.linuxaudio.org
#sudo service triggerhappy stop