[SOLVED] AudioEngine & Advancedlauncher, ALSA
#1
I want to run emulators using advancedlauncher but I get no sound while using xbmc since audioengine seems to hog the soundcard instead of allowing alsa to use a dmix interface.

Is it possible to make xbmc audioengine use a device created with asound.conf?
People have spoken about using device "Default" but I cannot find it in my list on xbmc even tough
I have a device
Code:
pcm.!default {...
in asound.conf

Btw, my XBMC version:
XBMC (12.2 Git:Unknown), Platform: Linux

--Edit--
This has been solved with a patch to Advancedlauncher below,
AdvancedLauncher git repo has been updated with a more generic patch (https://github.com/Angelscry/plugin.prog...d.launcher)
Reply
#2
You have to suspend audio engine correctly with the API that is given.

Writing alsa rules to get a default device available is not Audio Engines work, that is your work as the user of this computer.
AE by default releases the Audio device 10 seconds after the last sound has been played. When envoking external applications, use something like this:
Code:
xbmc.executebuiltin("PlayerControl(Stop)")
xbmc.audioSuspend()
xbmc.enableNavSounds(False)
// start your application here
xbmc.audioResume()
xbmc.enableNavSounds(True)

xbmc on linux does not use the default device, it enumerates what is given by alsa itself. But again - the AE sound device is not transfered to the "external application". You need a minimal .asoundrc for this application to work.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#3
So there's no confusion here, asound.conf is a alsa global configuration file and .asoundrc is per user alsa configuration file (use one or the other not both), How and what you need to put in there in order to what you need is a different matter), may affect XBMC as well so beware if you break XBMC it may be because what you have in either of those files may be invalid.

uNi
Reply
#4
Thenks guys!

This is working fine!
Diff: .xbmc/addons/plugin.program.advanced.launcher/resources/lib/launcher_plugin.py
Code:
--- launcher_plugin.py_before    2013-05-11 10:08:01.148624586 +0200
+++ launcher_plugin.py    2013-05-11 10:05:53.888627202 +0200
@@ -1566,7 +1566,11 @@
                     elif (sys.platform.startswith('linux')):
                         if ( self.settings[ "lirc_state" ] ):
                             xbmc.executebuiltin('LIRC.stop')
+                        xbmc.audioSuspend()
+                        xbmc.enableNavSounds(False)
                         os.system("\"%s\" %s " % (launcher["application"], arguments))
+                        xbmc.audioResume()
+                        xbmc.enableNavSounds(True)
                         if ( self.settings[ "lirc_state" ] ):
                             xbmc.executebuiltin('LIRC.start')
                     elif (sys.platform.startswith('darwin')):
@@ -1758,7 +1762,11 @@
                         elif (sys.platform.startswith('linux')):
                             if ( self.settings[ "lirc_state" ] ):
                                 xbmc.executebuiltin('LIRC.stop')
+                            xbmc.audioSuspend()
+                            xbmc.enableNavSounds(False)
                             os.system("\"%s\" %s " % (application, arguments))
+                            xbmc.audioResume()
+                            xbmc.enableNavSounds(True)
                             if ( self.settings[ "lirc_state" ] ):
                                 xbmc.executebuiltin('LIRC.start')
                         elif (sys.platform.startswith('darwin')):

Noticed another thing, to get some emulators working (eg mupen64) you have to
Edit Launcher -> Advanced Modifications -> Toggle XBMC int windowed mode: on
Reply
#5
Feel free to full edit main post and mark as solved Big Grin

uNi
Reply
#6
@Nortin!

Great - I appreciate you going into the coding direction. Please try to send it to the Advanced Launcher guys, cause this will fix a whole lot of problems multiple users have.

Thanks very much again for helping and implementing the suggestions. I am really thankful for this. Every help on making AE less rough is highly appreciated.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#7
(2013-05-11, 11:31)fritsch Wrote: @Nortin!

Great - I appreciate you going into the coding direction. Please try to send it to the Advanced Launcher guys, cause this will fix a whole lot of problems multiple users have.

Thanks very much again for helping and implementing the suggestions. I am really thankful for this. Every help on making AE less rough is highly appreciated.
Spotted... will be surely integrated into the next version of Advanced Launcher... Thanks. Wink
Reply
#8
@Angelscry:
Thanks for the inclusion.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#9
Hey Guys!

I am having this same problem, how do i implement Nortin's solution?

Do i need to edit: .xbmc/addons/plugin.program.advanced.launcher/resources/lib/launcher_plugin.py ?

Or maybe edit my asound.conf ?

Thanks!

D
Reply
#10
(2014-01-06, 00:48)DianeDrews Wrote: Hey Guys!

I am having this same problem, how do i implement Nortin's solution?

Do i need to edit: .xbmc/addons/plugin.program.advanced.launcher/resources/lib/launcher_plugin.py ?

Or maybe edit my asound.conf ?

Thanks!

D
Nortin's solution have been already implemented into Advanced Launcher since version 2.0.5. So... try to edit the asound.conf file.
Reply

Logout Mark Read Team Forum Stats Members Help
[SOLVED] AudioEngine & Advancedlauncher, ALSA0