[RELEASE] WebBrick Systems (Scripts) Home Automation Control Addons
#8
This is a really great script, thanks =)

But i have problem with the phone/door script.

I get an error(in the log) whe i try to close the doorbell popup when nothing is playing. On audio on video it works great.
I'm not great at python, but when i added the ELSE statemen at the end like this it works great:
Code:
try:
        player = xbmc.Player()
        if player.isPlayingAudio():
            #dont pause with a timeout
            doorwindow.doTimeout(45)

        elif player.isPlayingVideo():
            #pause , no timeout
            player.pause()
    except Exception, e:
        xbmc.log(str(e))
        #set timeout
        doorwindow.doTimeout(45)
    else:
        doorwindow.doTimeout(45)
I have no clue on how TRY and EXCEPTION works, but with the else statement it works perfect. Is this a bug or is something fault on my end?

Also; i think i read somewhere that "playSFX" will play the sound even when music or video is playing. But this is not true? (atleast it doesnt do that in this situation)

Again, thanks for this great script Smile
Reply


Messages In This Thread
[No subject] - by Mnuu - 2010-10-05, 11:21
[No subject] - by prae5 - 2010-10-05, 11:26
[No subject] - by Mnuu - 2010-10-05, 11:48
[No subject] - by Livin - 2010-10-06, 08:19
[No subject] - by Mnuu - 2010-10-06, 11:59
[No subject] - by Mnuu - 2010-10-06, 13:36
[No subject] - by qwerdy - 2010-10-12, 00:46
[No subject] - by Mnuu - 2010-10-12, 11:18
[No subject] - by qwerdy - 2010-10-12, 14:28
[No subject] - by Mnuu - 2010-10-12, 14:59
[No subject] - by speed32219 - 2011-08-23, 01:14
Logout Mark Read Team Forum Stats Members Help
[RELEASE] WebBrick Systems (Scripts) Home Automation Control Addons1