I was thinking about the same for similar reasons (turning on and off the TV/AVR based on certain events), but did not dare to ask for it. However, this is not actually about a "delay" of the event. It is more about a "grace period" until a certain task gets executed. During that grace period you still can cancel the already initiated task. This brings us to the question: Which events shall cancel the task before it will be executed?
I guees you could specify the cancle event.
Let say:
onPlayBackStarted (starts amp)
onPlayBackEnded (wait 1min)
onPlayBackStarted (cancles the previous event)
This is how i have it set up in LMS:
Yes this would be possibility but then i loose functionality from LMS server which uses the same amp.
Without more detail, I don't think I can provide more help.
See updated gist at same link above.
You would configure the events to call the same python script for onPlaybackstarted and onPlaybackEnded, but pass 'start' and 'end' as respective parameters.
It works!
I just had to fix this "xbmc.Player.isPlaying()" to this "xbmc.Player().isPlaying()"
Thx! This has raised WAF trough the roof
(2016-04-22, 22:59)snoopy86 Wrote: [ -> ]It works!
I just had to fix this "xbmc.Player.isPlaying()" to this "xbmc.Player().isPlaying()"
Thx! This has raised WAF trough the roof
Sorry - that's what happens when I code from my phone
I'm glad that it's working for you. My regards to ur wife
Good news!!!
The addon has been accepted to the official repo.
Thank you all for your patience in pointing out bugs and helping me get this to this point.
I couldn't have done it without you.
I'm trying for a few days but I dind't get it working.
I want to call the advanced wake on lan addon. when playback is starting.
What did I have to configure?
Task 1: Scipt and choose default.py from script.advanced.wol directory
And Event 1: On Playback started + task 1
Right?
I'm trying to run an HTTP Post command on onShutdown event. It appears to work for all events but onShutdown. I set the same task to run on start of playback, Kodi startup, and shutdown. It works in each case but when I shut down Kodi, it does not run. Is the HTTP Post command supported for the onShutdown event?
Yes it does. Check your log, read the post linked to in the previous post and if needed post the LINK to the log as directed here.
Thanks. After I enabled logging, it actually worked once but the next time I tried, it did not work again. Here are both logs from when it worked and didn't:
Did not work:
http://goo.gl/4jN06I
21:05:17 T:3264 NOTICE: $$$ [kodi.callbacks] - Shutdown started
21:05:17 T:3264 NOTICE: $$$ [kodi.callbacks] - Shutdown complete
Worked:
http://goo.gl/0cegvH
21:03:30 T:3964 NOTICE: $$$ [kodi.callbacks] - Shutdown started
21:03:30 T:1952 NOTICE: $$$ [kodi.callbacks] - Task starting for onShutdown
21:03:31 T:1952 NOTICE: $$$ [kodi.callbacks] - Command for Task T1, Event onShutdown completed succesfully!
The following message was returned: Prepped URL:
http://192.168.1.122:8080/redeye/rooms/0...mandId=553
Status: 200
Response for POST: No response received
21:03:31 T:1952 NOTICE: $$$ [kodi.callbacks] - Task finalized for onShutdown
21:03:31 T:3964 NOTICE: $$$ [kodi.callbacks] - Shutdown complete
Both times, I followed the same exact steps.
- Opened Kodi
- Went to Addons > Kodi Callbacks Settings
- Clicked Write Settings into Kodi log
- Navigated to home
- Clicked Shutdown