Any experience with Squeezelite Player
Hi,
sorry to report here in the issue section I am quite sure it's only a config problem I have. Maybe someone has an idea. I am not an Linux expert but with some try and Error and your excelent documentation I could setup the aes-daemon. I could pass all tests and also could do a speaker test and play a wav File.
In the next step I wanted to use my player "squeezelite". I am not sure if you have any experience with that it's really working great with all my soundcards. However with the AES daemon I only get strange noise from my speaker and an error on my AES Audio-DSP reporting: "Compromised - Packet Missing "
I am starting the player with these commands:
./squeezelite -a ::24: -R -u vME:::28 -r 48000-48000 -d all=debug -o plughw:CARD=RAVENNA
This basically opens the Soundcard with a fixed rate of 48000 and format S24_LE. Music is alwasy resampled to 48000
alsa_open:422 opened device plughw:CARD=RAVENNA using format: S24_LE sample rate: 48000 mmap: 1
Any help is appreciated.
Thanks Alex
I understand everything is ok when you use aplay or speaker-test but you have troubles with the squeezelite player. This can depend on how you setup some ALSA parameters of the playback device and in particular the buffer size and periods. I would suggest you try to playback on the RAVENNA device via an ALSA plugin instead of doing it directly. To do so use the following instructions:
- add the following configuration to your /etc/asound.conf
pcm.source_1 {
type dmix
ipc_key 0x11111
slave {
pcm "hw:CARD=RAVENNA"
buffer_size 4096
channels 4
rate 48000
format S24_3LE
}
bindings { 0 0 1 1 }
}
- use the plughw:source_1 as playback device on your player.
Hi,
appreciate your help and support though it is not really your response :_) Thank you. I followed your recommendation however it does not open the device. I am not sure if there is just a syntax error but it gives me that output:
a@audioserver:~/programs$ sudo ./squeezelite -W -n AES -R -u vME:::28 -r 48000-48000 -d all=debug -o plughw:source_1
[17:19:45.195925] stream_init:448 init stream
[17:19:45.195995] stream_init:449 streambuf size: 2097152
[17:19:45.197536] output_init_alsa:940 init output
[17:19:45.197557] output_init_alsa:980 requested alsa_buffer: 40 alsa_period: 4 format: any mmap: 1
[17:19:45.197567] output_init_common:350 outputbuf size: 3528000
[17:19:45.197597] output_init_common:374 idle timeout: 0
[17:19:45.198262] ALSA _snd_pcm_hw_open:1829 Invalid value for card
[17:19:45.198281] test_open:281 playback open error: No such device
[17:19:45.198287] output_init_common:391 unable to open output device: plughw:source_1
I have created the asound.conf and copied the contect into this file. I also see the ALSA plugin.
a@audioserver:~/programs$ sudo ./squeezelite -l
Output devices:
null - Discard all samples (playback) or generate zero samples (capture)
source_1
hw:CARD=RAVENNA,DEV=0 - Merging RAVENNA, Merging RAVENNA - Direct hardware device without any conversions
plughw:CARD=RAVENNA,DEV=0 - Merging RAVENNA, Merging RAVENNA - Hardware device with all software conversions
default:CARD=RAVENNA - Merging RAVENNA, Merging RAVENNA - Default Audio Device
sysdefault:CARD=RAVENNA - Merging RAVENNA, Merging RAVENNA - Default Audio Device
dmix:CARD=RAVENNA,DEV=0 - Merging RAVENNA, Merging RAVENNA - Direct sample mixing device
dsnoop:CARD=RAVENNA,DEV=0 - Merging RAVENNA, Merging RAVENNA - Direct sample snooping device
I am not sure where the problem is - Sorry. Any idea?
Thanks again Alex
yes, sorry. As playback device use plug:source_1
For example after creating the plug in the configuration file I can run the following command:
aplay -D plug:source_1 -r 48000 -c 2 ...
Hi, thanks again.
this is working:
a@audioserver:~/programs$ sudo speaker-test -D plug:source_1 -r 48000 -c 2 -t sine
speaker-test 1.2.4
Wiedergabe-Gerät ist plug:source_1
Stream-Parameter sind 48000 Hz, S16_LE, 2 Kanäle
Sinuswelle mit Frequenz 440,0000 Hz
Rate ist 48000 Hz (angefordert: 48000 Hz)
Puffergröße von 96 bis 1008
Periodengröße von 48 bis 48
Verwende maximale Puffergröße 1008
Perioden = 4
gesetzt: period_size = 48
gesetzt: buffer_size = 1008
0 - Front Left
However with queezelite theres still some problems. (I marked it in the output below) Maybe you have another idea if not I can ask in the squeezelite forum.
Apreciate your help
Thanks Alex
/programs$ sudo ./squeezelite -W -n AES -a ::24:1 -R -u vME:::28 -r 48000-48000 -d all=debug -o plug:source_1
[20:11:52.888257] stream_init:448 init stream
[20:11:52.888327] stream_init:449 streambuf size: 2097152
[20:11:52.889790] output_init_alsa:940 init output
[20:11:52.889813] output_init_alsa:980 requested alsa_buffer: 40 alsa_period: 4 format: 24 mmap: 1
[20:11:52.889821] output_init_common:350 outputbuf size: 3528000
[20:11:52.889848] output_init_common:374 idle timeout: 0
**[20:11:52.890444] ALSA snd_pcm_hw_open:1715 open '/dev/snd/pcmC2D0p' failed (-77)**
[20:11:52.890899] output_init_common:422 supported rates: 48000
[20:11:52.892284] output_init_alsa:1006 memory locked
[20:11:52.892309] output_init_alsa:1012 glibc detected using mallopt
[20:11:52.892393] output_init_alsa:1032 set output sched fifo rt: 45
[20:11:52.892405] decode_init:153 init decode
[20:11:52.892452] register_dsd:908 using dsd to decode dsf,dff
[20:11:52.892457] register_alac:555 using alac to decode alc
[20:11:52.892462] register_faad:663 using faad to decode aac
[20:11:52.892467] register_vorbis:380 using vorbis to decode ogg
[20:11:52.892472] register_opus:324 using opus to decode ops
[20:11:52.892481] register_flac:332 using flac to decode ogf,flc
[20:11:52.892486] register_pcm:468 using pcm to decode wav,aif,pcm
[20:11:52.892808] register_mad:423 using mad to decode mp3
[20:11:52.892816] decode_init:194 include codecs: exclude codecs:
[20:11:52.892899] resample_init:362 resampling sync recipe: 0x36, flags: 0x00, scale: 0.89, precision: 28.0, passband_end: 0.00000, stopband_begin: 0.00000, phase_response: -1.0
[20:11:52.892934] discover_server:788 sending discovery
[20:11:52.893089] discover_server:799 got response from: 10.7.120.129:3483
[20:11:52.893106] slimproto:887 connecting to 10.7.120.129:3483
[20:11:52.893153] slimproto:926 connected
[20:11:52.893162] slimproto:937 local player
[20:11:52.893166] sendHELO:142 mac: d0:50:99:af:6d:be
[20:11:52.893170] sendHELO:144 cap: CanHTTPS=1,Model=squeezelite,AccuratePlayPoints=1,HasDigitalOut=1,HasPolarityInversion=1,Firmware=v1.9.8-1294,ModelName=SqueezeLite,MaxSampleRate=48000,dsf,dff,alc,aac,ogg,ops,ogf,flc,wav,aif,pcm,mp3,loc
[20:11:52.893373] output_thread:687 open output device: plug:source_1
[20:11:52.893387] alsa_open:351 opening device at: 48000
[20:11:52.893950] alsa_open:422 opened device plug:source_1 using format: S24_LE sample rate: 48000 mmap: 1
[20:11:52.893978] alsa_open:513 buffer: 40 period: 4 -> buffer size: 192 period size: 48
[20:11:52.894023] process:521 strm
[20:11:52.894031] process_strm:274 strm command q
[20:11:52.894036] decode_flush:236 decode flush
[20:11:52.894040] output_flush:435 flush output buffer
[20:11:52.894045] sendSTAT:189 STAT: STMf
[20:11:52.894076] process:521 setd
[20:11:52.894083] sendSETDName:248 set playername: AES
[20:11:52.894101] process:521 setd
[20:11:52.894110] process:521 aude
[20:11:52.894120] process_aude:415 enable spdif: 1 dac: 1
[20:11:52.894130] process:521 audg
[20:11:52.894135] process_audg:433 audg gainL: 3840 gainR: 3840 adjust: 1
[20:11:52.894141] set_volume:233 setting internal gain left: 3840 right: 3840
[20:11:52.904121] output_thread:717 XRUN
[20:11:52.914169] output_thread:717 XRUN
[20:11:52.924261] output_thread:717 XRUN
[20:11:52.934366] output_thread:717 XRUN
[20:11:52.944506] output_thread:717 XRUN
[20:11:52.954652] output_thread:717 XRUN
[20:11:52.964816] output_thread:717 XRUN
[20:11:52.975005] output_thread:717 XRUN
[20:11:52.985165] output_thread:717 XRUN
[20:11:52.995337] output_thread:717 XRUN
[20:11:53.005549] output_thread:717 XRUN
[20:11:53.015692] output_thread:717 XRUN
[20:11:53.025854] output_thread:717 XRUN
[20:11:53.036031] output_thread:717 XRUN
[20:11:53.046204] output_thread:717 XRUN
[20:11:53.056379] output_thread:717 XRUN
[20:11:53.066597] output_thread:717 XRUN
[20:11:53.076740] output_thread:717 XRUN
[20:11:53.086914] output_thread:717 XRUN
[20:11:53.097053] output_thread:717 XRUN
[20:11:53.107229] output_thread:717 XRUN
[20:11:53.117402] output_thread:717 XRUN
Is there a mismatch in the format? You said Squeezelite is S24_LE; the daemon is S24_3LE. Can they interoperate?
Can they interoperate?
yes, the PCM encoding conversion is done by the kernel module but if you open the audio stream with S24_LE it means your player should provide 4 bytes samples with a 0 padding for the most significant byte. For example: S24_3LE : 0x123456(in 3bytes, No padding) S24_LE : 0x00123456(in 4bytes, MSB 0 padding)
Hi,
thanks a lot. However I did not get it to run with Squeezelite. I am not sure what the issue is as you can play tracks with aplay or do a speaker test.
a@audioserver:~/programs$ sudo speaker-test -D plug:source_1 -r 48000 -c 2 -t sine
However with squeezelite starting and adressing the Ravenna card I only get this XRUN output errors in the log file.
With regards to:
druidlabs commented 19 days ago Is there a mismatch in the format? You said Squeezelite is S24_LE; the daemon is S24_3LE. Can they interoperate?
Do I have to start the player in a different?
Thanks Alex