Posts: 193
Joined: Apr 2010
Reputation:
0
Hi,
very nice addon.
A very useful setting could be to reset to a specific profile on startup.
Posts: 9
Joined: May 2017
Reputation:
0
Hello all. There is no auto switching profiles in Kodi. OpenELEC 8.0.3+Kodi 17+Audio Profiles 1.2.0. How to fix? Also 1.2.5 addon version already available. Will it be updated via official repo?
Thanks.
Posts: 1,272
Joined: Mar 2006
Reputation:
27
has someone noticed that if i have two profiles one with "use full screen window" activated and another without, switching between profiles kodi freeze?
Peppe
Posts: 6
Joined: May 2015
Reputation:
0
This addon is really, or almost, what I was needing.
I managed to get the two audio profiles
1: HDMI audio for everything
2: Analog audio for playing music (goes to the amp)
The automatic swithching of profiles works perfectly except:
When I start playing music using an android app, music starts but is probably not considered as music by the switching mechanism so soundprofile 1 is still being used.
Is there any way to get it to switch to a different profile when music is being played by a remote device?
Posts: 6
Joined: May 2015
Reputation:
0
In fact what I meant is that I'm using upnp apps such as "Kodi Remote" or "Yatse"
I checked, and the 'data' catched by onNotification(self, sender, method, data) contains something like this (don't have the exact result available here):
{u'item': {u'type': u'unknown'}, u'player': {u'playerid': 1, u'speed': 1}}
So I added this: (without removing the original two lines concerning music)
if ADDON.getSetting('auto_music') in profiles and 'item' in data and 'type' in data['item'] and 'unknown' in data['item']['type']:
xbmc.executebuiltin('XBMC.RunScript(' + ADDON_ID + ', ' + ADDON.getSetting('auto_music') + ')')
I'm aware this solution is relatively dramatic and will probable bring some unwanted side-effects ...
Pherphaps there is a different way to figure out music is being played... ?
Posts: 6
Joined: May 2015
Reputation:
0
2017-06-01, 21:00
(This post was last modified: 2017-08-08, 14:11 by quatschou.)
Ok, So I ended up by writing thee following which seems to work for the moment ...
# music
if ADDON.getSetting('auto_music') in profiles and 'item' in data and 'type' in data['item'] and 'song' in data['item']['type']:
xbmc.executebuiltin('XBMC.RunScript(' + ADDON_ID + ', ' + ADDON.getSetting('auto_music') + ')')
if ADDON.getSetting('auto_music') in profiles and 'item' in data and 'type' in data['item'] and 'unknown' in data['item']['type']:
if xbmc.getCondVisibility("!Player.HasVideo()"):
xbmc.executebuiltin('XBMC.RunScript(' + ADDON_ID + ', ' + ADDON.getSetting('auto_music') + ')')
if ADDON.getSetting('auto_movies') in profiles and 'item' in data and 'type' in data['item'] and 'unknown' in data['item']['type']:
if xbmc.getCondVisibility("Player.HasVideo()"):
xbmc.executebuiltin('XBMC.RunScript(' + ADDON_ID + ', ' + ADDON.getSetting('auto_movies') + ')')
Posts: 2
Joined: Jul 2017
Reputation:
0
Thanks for the wonderful add-on, it works in kodi 14.2, Openelec 5.0.8.
I am totally new to Kodi/Openelec
The add-on works if I have a keyboard plugged into my box [Box is Intel i5 with openelec as operating system]. I press keyboard n to swop between the digital & headphones.
I used :
<keymap>
<global>
<keyboard>
<n>RunScript(script.audio.profiles,0)</n>
</keyboard>
</global>
</keymap>
My problem is I have a Harmony 650 remote and I just can’t figure out how to send an ‘n’ to the box from my remote. All the threads I have read on mapping a button suggest keymap editor add-on…but how ? I installed it and played a LOT to no avail.
I feel so silly because it just seems impossible after a few days of trying.
Using keymap editor I see that when I press n on keyboard it records the original button code of 61518, so I tried:
<keymap>
<FullScreenVideo>
<keyboard>
<obc61518>blue</obc61518>
<keyboard>
<FullScreenVideo>
<global>
<keyboard>
<n>RunScript(script.audio.profiles,0)</n>
</keyboard>
</global>
</keymap>
Didn’t work, pressing the blue button starts seek function.
I have these buttons free on my remote that I could use: #, record button, *
So how do I write a remote.xml that will send the letter n when I press one of the above buttons on my Harmony 650 remote?
Posts: 10
Joined: Aug 2015
Reputation:
1
faser
Junior Member
Posts: 10
Well first of all many thanks for this great addon. Unfortunately I have one issue. And that is that it seems Content being played from Music Addons (e.g. Radio) are not detected as "music" and therefore the audio profile for music is not being loaded. Is this a know limitation or something misconfigured on my side?