XU4 + Kodi + sound issue

Post Reply
speeedfire
Posts: 3
Joined: Tue May 07, 2019 6:29 pm
languages_spoken: english
ODROIDs: xu4
Has thanked: 1 time
Been thanked: 0
Contact:

XU4 + Kodi + sound issue

Unread post by speeedfire » Thu May 09, 2019 8:46 pm

Hy,
i used xu4 with the latest dietpi. But i dont have sound.

Code: Select all

root@DietPi:/etc# aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: OdroidXU4 [Odroid-XU4], device 0: Primary multicodec-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
CODE: SELECT ALL

root@DietPi:/etc# cat /etc/asound.conf
pcm.!default {
    type hw
    card 0
    device 0
    #format S16_LE
    #channels 2
    #rate 44100
}

ctl.!default {
    type hw
    card 0
}
The sound test is well played.

Code: Select all

root@DietPi:/etc# speaker-test -c2

speaker-test 1.1.3

Playback device is default
Stream parameters are 48000Hz, S16_LE, 2 channels
Using 16 octaves of pink noise
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
Time per period = 2,751413
 0 - Front Left
 1 - Front Right
^CTime per period = 3,833856
Bad information. This is 16 bit, 44kHz file.

Code: Select all

root@DietPi:/etc# aplay /mnt/data/dietpi_userdata/Music/Andy\ C\ -\ Nightlife\ 6/01\ -\ DC\ Breaks\ -\ Shaman\ \(Original\ Mix\).mp3 -V -v
Playing raw data '/mnt/data/dietpi_userdata/Music/Andy C - Nightlife 6/01 - DC Breaks - Shaman (Original Mix).mp3' : Unsigned 8 bit, Rate 8000 Hz, Mono
aplay: set_params:1299: Sample format non available
Available formats:
- S16_LE
- S24_LE
Kodi is stop playing the movie, and no sound.

How can i solve the issue? Alsa, or codec issue?

User avatar
odroid
Site Admin
Posts: 32734
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Has thanked: 220 times
Been thanked: 369 times
Contact:

Re: XU4 + Kodi + sound issue

Unread post by odroid » Fri May 10, 2019 9:07 am

Do you use DietPi OS image?
Which Kernel version and Kodi version do you try?

speeedfire
Posts: 3
Joined: Tue May 07, 2019 6:29 pm
languages_spoken: english
ODROIDs: xu4
Has thanked: 1 time
Been thanked: 0
Contact:

Re: XU4 + Kodi + sound issue

Unread post by speeedfire » Fri May 10, 2019 4:44 pm

odroid wrote:
Fri May 10, 2019 9:07 am
Do you use DietPi OS image?
Which Kernel version and Kodi version do you try?
Yes, i did.

Code: Select all

Linux DietPi 4.14.66+ #1 SMP PREEMPT Thu Aug 23 05:59:33 UTC 2018 armv7l GNU/Linux
Tomorrow i solved the problem. This asound config solved my sound issue.

https://dietpi.com/phpbb/viewtopic.php? ... 907#p17888

Code: Select all

root@DietPi:~# cat /etc/asound.conf
pcm.dmixed {
        type asym
        playback.pcm {
                type dmix
                ipc_key 5678293
                ipc_perm 0660
                ipc_gid audio

                slave {
                        channels 2 # make 6 or 5.1 channel
                        pcm {
                                format S16_LE # S32_LE
                                rate 44100 # can also be 44100
                                type hw
                                card 0 # your card
                                device 0 # your device
                                subdevice 0 #important?
                        }

                        period_size 1024
                        buffer_size 2048
                }

                bindings {
                        0 0
                        1 1
# Uncomment below if using 6 channel
#                       2 2
#                       3 3
#                       4 4
#                       5 5
                }
        }
        capture.pcm "hw:0"
}

pcm.!default {
        type plug
        slave.pcm "dmixed"
}

User avatar
odroid
Site Admin
Posts: 32734
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID
Has thanked: 220 times
Been thanked: 369 times
Contact:

Re: XU4 + Kodi + sound issue

Unread post by odroid » Fri May 10, 2019 4:56 pm

Glad to hear you found a solution.
These users thanked the author odroid for the post:
speeedfire (Fri May 10, 2019 5:06 pm)

sondra4
Posts: 1
Joined: Tue Jun 25, 2019 8:26 pm
languages_spoken: english
Has thanked: 0
Been thanked: 0
Contact:

Re: XU4 + Kodi + sound issue

Unread post by sondra4 » Thu Jun 27, 2019 2:30 pm

speeedfire wrote:
Fri May 10, 2019 4:44 pm
odroid wrote:
Fri May 10, 2019 9:07 am
Do you use DietPi OS image?
Which Kernel version and Kodi version do you try?
Yes, i did.

Code: Select all

Linux DietPi 4.14.66+ #1 SMP PREEMPT Thu Aug 23 05:59:33 UTC 2018 armv7l GNU/Linux
Tomorrow i solved the problem. This asound config solved my sound issue.

https://dietpi.com/phpbb/viewtopic.php? ... 907#p17888 Kroger Feedback

Code: Select all

root@DietPi:~# cat /etc/asound.conf
pcm.dmixed {
        type asym
        playback.pcm {
                type dmix
                ipc_key 5678293
                ipc_perm 0660
                ipc_gid audio

                slave {
                        channels 2 # make 6 or 5.1 channel
                        pcm {
                                format S16_LE # S32_LE
                                rate 44100 # can also be 44100
                                type hw
                                card 0 # your card
                                device 0 # your device
                                subdevice 0 #important?
                        }

                        period_size 1024
                        buffer_size 2048
                }

                bindings {
                        0 0
                        1 1
# Uncomment below if using 6 channel
#                       2 2
#                       3 3
#                       4 4
#                       5 5
                }
        }
        capture.pcm "hw:0"
}

pcm.!default {
        type plug
        slave.pcm "dmixed"
}
Thanks for this. This worked exactly as expected.

Exactly what I needed! You just saved me several hours.

Post Reply

Return to “Issues”

Who is online

Users browsing this forum: No registered users and 1 guest