Hi
I have NanoPi Neo v1.31 with DietPi v6.30.0 installed. Audio out is on board on 5-pin connector.
Audio is enabled in dietpi-config. But there is no sound.
# aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: Dummy [Dummy], device 0: Dummy PCM [Dummy PCM]
Subdevices: 8/8
Subdevice #0: subdevice #0
Subdevice #1: subdevice #1
Subdevice #2: subdevice #2
Subdevice #3: subdevice #3
Subdevice #4: subdevice #4
Subdevice #5: subdevice #5
Subdevice #6: subdevice #6
Subdevice #7: subdevice #7
card 1: Loopback [Loopback], device 0: Loopback PCM [Loopback PCM]
Subdevices: 8/8
Subdevice #0: subdevice #0
Subdevice #1: subdevice #1
Subdevice #2: subdevice #2
Subdevice #3: subdevice #3
Subdevice #4: subdevice #4
Subdevice #5: subdevice #5
Subdevice #6: subdevice #6
Subdevice #7: subdevice #7
card 1: Loopback [Loopback], device 1: Loopback PCM [Loopback PCM]
Subdevices: 8/8
Subdevice #0: subdevice #0
Subdevice #1: subdevice #1
Subdevice #2: subdevice #2
Subdevice #3: subdevice #3
Subdevice #4: subdevice #4
Subdevice #5: subdevice #5
Subdevice #6: subdevice #6
Subdevice #7: subdevice #7
card 2: Codec [H3 Audio Codec], device 0: CDC PCM Codec-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 3: allwinnerhdmi [allwinner,hdmi], device 0: 1c22800.i2s-i2s-hifi i2s-hifi-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0
# cat /etc/asound.conf
pcm.!default {
type hw
card 2
device 0
}
ctl.!default {
type hw
card 2
}
This command won’t output any sound:
# speaker-test
speaker-test 1.1.3
Playback device is default
Stream parameters are 48000Hz, S16_LE, 1 channels
Using 16 octaves of pink noise
Rate set to 48000Hz (requested 48000Hz)
Buffer size range from 256 to 262144
Period size range from 128 to 32768
Using max buffer size 262144
Periods = 4
was set period_size = 32768
was set buffer_size = 262144
0 - Front Left
Time per period = 2.690483
I’ve tried all hw devices with speaker-test, one or two channels with no results (e.g. speaker-test -c2 -Dhw:0,0 and all working hw combinations).
This won’t output any sound either :
# aplay /mnt/dietpi_userdata/Music/fourdee_tech.ogg -f cd
Playing raw data '/mnt/dietpi_userdata/Music/fourdee_tech.ogg' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
Thanks in advance for any help / suggestions how to troubleshoot this further.
Edit1 : I just run my NanoPi from UbuntuCore 16.04 FriendlyArm image, and sound works out of the box. Output from aplay -l and cat /etc/asound.conf looks identical.
Edit2: when i try to play other file (that worked on FriendlyArm image) on DietPi i got error :
aplay /mnt/dietpi_userdata/Music/test.wav
Playing WAVE '/mnt/dietpi_userdata/Music/test.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
aplay: pcm_write:2011: write error: Input/output error
Now i’m trying to compare output of debug script (https://alsa.opensrc.org/Aadebug) from both images.
Edit3: i’ve created an issue https://github.com/MichaIng/DietPi/issues/3616