I'm trying to test SPDIF Input on Hifiberry Digi+ I/O.
I'm using the latest headless raspbian installed from NOOBS.
$ cat /etc/issue
Raspbian GNU/Linux 8 \n \l
$ uname -a
Linux raspberrypi 4.9.35-v7+ #1014 SMP Fri Jun 30 14:47:43 BST 2017 armv7l GNU/Linux
Playback seems to work fine:
$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: sndrpihifiberry [snd_rpi_hifiberry_digi], device 0: HifiBerry Digi HiFi wm8804-spdif-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0
pi@raspberrypi:~ $ speaker-test -c 2 -f 1000 -t sine
speaker-test 1.0.28
Playback device is default
Stream parameters are 48000Hz, S16_LE, 2 channels
Sine wave rate is 1000.0000Hz
Rate set to 48000Hz (requested 48000Hz)
Buffer size range from 128 to 131072
Period size range from 64 to 65536
Using max buffer size 131072
Periods = 4
was set period_size = 32768
was set buffer_size = 131072
0 - Front Left
1 - Front Right
^CTime per period = 1.522844
But capture is not working.
I can list the capture device:
$ arecord -l
**** List of CAPTURE Hardware Devices ****
card 0: sndrpihifiberry [snd_rpi_hifiberry_digi], device 0: HifiBerry Digi HiFi wm8804-spdif-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0
But arecord is freezing when trying to start a capture:
$ arecord -d 5 /tmp/speaker-test.wav
Recording WAVE '/tmp/speaker-test.wav' : Unsigned 8 bit, Rate 8000 Hz, Mono
When canceling the arecord execution, I can see a DMA error message in dmesg:
[ 787.405484] bcm2835-dma 3f007000.dma: DMA transfer could not be terminated
Should the capture work? Is it support supported by the machine/codec driver?
Thanks,
Sergio Prado