Linux - Frodo - No sound after resume from suspend

  Thread Rating:
  • 3 Votes - 3.67 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
bahman Offline
Junior Member
Posts: 18
Joined: Dec 2012
Reputation: 0
Post: #1
Hi,

Running Frodo Beta - Openelec ION 64bit build on a Zotac ID41.
Audio output on HDMI to my DTS/AC3 capable AV Receiver.

No issues with sound from a cold boot - all works as intended.
However when I resume from suspend video is OK but sound doesn't come back.
I can get sound back if I perform a reboot but this defeats the purpose of resume from suspend.

Same issue running the earlier Frodo Beta's.

Doesn't appear that I'm the only one having this issue even on non-ION machines:
http://forum.xbmc.org/showthread.php?tid=137432
and
http://openelec.tv/forum/68-audio/55789-...om-suspend

Any thoughts on what could be the issue?
Is it a recognised issue/bug by the Dev's?

Thanks in advance
find quote
Wraul Offline
Junior Member
Posts: 29
Joined: Jan 2010
Reputation: 0
Post: #2
I have the same problem on Arch Linux using HDMI through a GeForce 210.

The sound returns if I restart XBMC so no need for a reboot.
This makes me believe that XBMC is the causing this.
find quote
teeedubb Offline
Donor
Posts: 2,014
Joined: Mar 2010
Reputation: 41
Location: Down Under
Post: #3
This used to happen to me occasionally and I couldn't pin point why. Having xbmc restart on resume via a hook in /etc/pm/sleep.d/ solved this for me... and as a bonus xbmc now always loads to the home screen.

My Add-ons, only available for XBMC:
Steam Launcher|Music Party Mode|Reboot2oOS|Triple J Radio
find quote
bahman Offline
Junior Member
Posts: 18
Joined: Dec 2012
Reputation: 0
Post: #4
this should be a recognised issue given a number of people are having the same problem

Performing a reboot via a script or from the menu isn't really an option for the non-techy audience.

Dev's what do you need to look into this further?
find quote
Kaio85 Offline
Junior Member
Posts: 12
Joined: Dec 2010
Reputation: 0
Post: #5
Hi.
I have the same problem (no hdmi sound after suspend). Eden worked perfect and after a reboot everything works fine.
My setup is:
Asrock 3D Vision 252B with pulse-eight HDMI-CEC
Pioneer VSX-1021K
Generic OpenELEC 3.0 (Beta 5) - 2.95.5 - i386 / Frodo Release Candidate 1

Thanks in advance
(2012-12-09 20:46)teeedubb Wrote:  This used to happen to me occasionally and I couldn't pin point why. Having xbmc restart on resume via a hook in /etc/pm/sleep.d/ solved this for me... and as a bonus xbmc now always loads to the home screen.

Can you please tell me how i can do this?

Thank you
(This post was last modified: 2012-12-15 16:42 by Kaio85.)
find quote
teeedubb Offline
Donor
Posts: 2,014
Joined: Mar 2010
Reputation: 41
Location: Down Under
Post: #6
Im running ubuntu + xbmc and have never used openelec so I dont know if my method will work for you, but here is my resume hook script:

cat /etc/pm/sleep.d/80_restartx
Code:
#!/bin/sh
# restart x + xbmc

if [ "$1" = "resume" ]
then

        /usr/bin/killall xinit

fi

IF openelec has the directory /etc/pm/sleep.d create the above script inside it, replace /usr/bin/killall xinit with whatever restarts xbmc for you and make it executable.

My Add-ons, only available for XBMC:
Steam Launcher|Music Party Mode|Reboot2oOS|Triple J Radio
find quote
kollock Offline
Junior Member
Posts: 13
Joined: Dec 2010
Reputation: 0
Post: #7
Same here. Xs35GT with openelec 3.0 b5.
find quote
wiad Offline
Junior Member
Posts: 5
Joined: Dec 2012
Reputation: 0
Post: #8
I have the same problem since upgrading to ubuntu 12.04 and xbmc frodo rc2 with asrock ion 330ht. After resuming from suspend, alsa seems to lose a couple of devices (as seen with "aplay -l") of which 'hdmi 0' is one. To get them back i need to run a force-reload of alsa, which crashes xbmc so then i need to restart xbmc too. I do this with a hook script in /etc/pm/sleep.d, as suggested before in this thread:

Code:
#!/bin/sh
# restart alsa and then x + xbmc
# to make hdmi audio work after resume

case "$1" in
resume)
  # Kill xbmc before reloading alsa, to avoid hangup
  /usr/bin/pkill xbmc.bin || /usr/bin/pkill -9 xbmc.bin
  # Reload alsa
  /sbin/alsa force-reload
  # Restart window manager to force restart of xbmc
  /usr/sbin/service lightdm restart
;;
esac


a bit crappy and not always working workaround, but better than nothing. The problem is in alsa, i would think.
(This post was last modified: 2012-12-27 08:06 by wiad.)
find quote
supertom44 Offline
Senior Member
Posts: 283
Joined: Apr 2010
Reputation: 0
Post: #9
I am having the same issue using openelec.

Just out of curiosity is everyone that is having this issue using an SSD?

[Image: widget]
find quote
ixnu Offline
Donor
Posts: 151
Joined: Sep 2010
Reputation: 19
Post: #10
For OpenElec, I had issues with SMB mounts upon resume. This script solved it.

Create this file:

.xbmc/addons/00restart/sleep.d/restart.power:

with this code:

Code:
#!/bin/sh

. /etc/profile

case "$1" in
  thaw|resume)
    /bin/killall -HUP xbmc.bin
    /bin/sleep 2s
    ;;
  *) exit $NA
    ;;
esac

chmod +x restart.power

reboot.
find quote
ixnu Offline
Donor
Posts: 151
Joined: Sep 2010
Reputation: 19
Post: #11
Looks like there is a ticket for this:

https://github.com/OpenELEC/OpenELEC.tv/issues/1564
find quote
supertom44 Offline
Senior Member
Posts: 283
Joined: Apr 2010
Reputation: 0
Post: #12
Thanks for the suggestion ixnu, I tried this but it still occurs.

[Image: widget]
find quote
bahman Offline
Junior Member
Posts: 18
Joined: Dec 2012
Reputation: 0
Post: #13
is there anyone else having this issue NOT running Openelec?

The openelec mod on their forum (link in my original post) suggests this is a XBMC issue and not an openelec issue.
The issue is only registered on the Openelec issue tracker - hasn't been registered as a bug for investigation for the XBMC team.
find quote
supertom44 Offline
Senior Member
Posts: 283
Joined: Apr 2010
Reputation: 0
Post: #14
I'm not sure where the issues lies to be honest.

I tried out Xbmcuntu the other day and I did not have this problem, however I did have a problem with sound after reboot and this was due to the fact I was using a ssd, no audio devices where detected. To solve this I added a sleep before loading the Lightdm (i think thats what it was called) service.

I'm guessing this is a similar problem as it only seems to occur when using an ssd.

[Image: widget]
find quote
wiad Offline
Junior Member
Posts: 5
Joined: Dec 2012
Reputation: 0
Post: #15
i don't have a ssd and i dont run openelec (running ubuntu 12.04). Since 'aplay -l' on my system is missing devices after a resume from suspend i'm having a hard time believing the problem lies with xbmc. As i said before, alsa is a more likely suspect.
(This post was last modified: 2013-01-03 08:18 by wiad.)
find quote
Post Reply