Page 40 of 94

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Tue Jan 08, 2013 12:15 am
by jonib
So first are you using the actions from XBMC2\Buttons\Remote? as those have different actions based on where you are in XBMC and can be changed in the Keymaps\remote.xml.
sunny25a wrote:Well, this is not really a specific one. I just use different actions with one key. Let give you two examples:
- I have a key exit on my remote. During media playback it just stops the video. Only in HomeScreen XBMC closes. With the help of the keymap.xml I could easily do that.
You could use any button in XBMC2\Buttons\Remote\ that you don't use and modify Keymaps\remote.xml for that button to do the same.
- I have an Info key on my remote. During media Playback the menu appears, on the home Screen the System Info appears, using it on a selected media, file the info for this appears.
A bit depending on the skin you use XBMC2\Buttons\Remote\Info should work similar or again you can modify Keymaps\remote.xml to make it work exactly like you want.

jonib

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Thu Jan 17, 2013 5:24 am
by Lunatixz
Hoping someone could help... I would like eventghost to receive a trigger when a xbmc addon starts and stops...
I had it setup to receive broadcasts events and modified my addons to send start and stop triggers...
but this method isn't working in frodo... anyone know of an easy alternative?

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Thu Jan 17, 2013 7:50 am
by blaher
Lunatixz wrote:Hoping someone could help... I would like eventghost to receive a trigger when a xbmc addon starts and stops...
I had it setup to receive broadcasts events and modified my addons to send start and stop triggers...
but this method isn't working in frodo... anyone know of an easy alternative?
viewtopic.php?f=9&t=1562&start=570#p24845 has the links that work for me with Frodo RC2. I'll try RC3 soon, but I doubt there's much change.

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Fri Jan 18, 2013 4:05 am
by Lunatixz
I appreciate the links... Didn't really find any useful information. I'm currently already running the latest code for EG... and all httpapi support in xbmc was dropped.

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Fri Jan 18, 2013 8:20 am
by jonib
Lunatixz wrote:Hoping someone could help... I would like eventghost to receive a trigger when a xbmc addon starts and stops...
I had it setup to receive broadcasts events and modified my addons to send start and stop triggers...
As far as I have read the broadcast events are still available in Frodo it just can't be controlled right now, don't know what the plan is.
but this method isn't working in frodo... anyone know of an easy alternative?
You should be able to create events using the JSON notification: JSONRPC.NotifyAll.

jonib

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Fri Jan 18, 2013 1:04 pm
by blaher
Lunatixz wrote:I appreciate the links... Didn't really find any useful information. I'm currently already running the latest code for EG... and all httpapi support in xbmc was dropped.
I just installed the latest XBMC: Frodo RC3 and using the latest plugin by jonib, I get all the proper events in the EventGhost. I think it uses JSON rather than HTTP now, but however it works, it works. :)

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Fri Jan 18, 2013 6:32 pm
by Lunatixz
blaher wrote:
Lunatixz wrote:I appreciate the links... Didn't really find any useful information. I'm currently already running the latest code for EG... and all httpapi support in xbmc was dropped.
I just installed the latest XBMC: Frodo RC3 and using the latest plugin by jonib, I get all the proper events in the EventGhost. I think it uses JSON rather than HTTP now, but however it works, it works. :)
I understand it works, lol that's not what i'm asking...
Json isn't the same as Http, your receiving events because of the script jonb wrote :)
I'm looking for an easy way to use python to generate a event in EG... the old httpapi was easy to do... not sure about jsonrcp...
I was hoping someone knows of an easy way, otherwise I will have to look into it... I want to add eg events when a xbmc addons starts and stops... in the past I modified the xbmc addons to use httpapi event... but this isn't working for json...

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Sat Jan 19, 2013 3:41 am
by blaher
Lunatixz wrote: I understand it works, lol that's not what i'm asking...
Ah ok, sorry. :)
I want to add eg events when a xbmc addons starts and stops.
Ah, I see. What do you use those for?

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Sat Jan 19, 2013 7:23 am
by jonib
Lunatixz wrote:I'm looking for an easy way to use python to generate a event in EG... the old httpapi was easy to do... not sure about jsonrcp...
I was hoping someone knows of an easy way, otherwise I will have to look into it... I want to add eg events when a xbmc addons starts and stops... in the past I modified the xbmc addons to use httpapi event... but this isn't working for json...
Try the below code in a Python script in EventGhost to create a custom event from XBMC.
There's a bit more code than necessary, it's from my test program.
You might need to change the url to match your setup, then change the "sender", "message" and "data" for the actual event. syntax for JSONRPC.NotifyAll here

Code: Select all

import urllib2
import json

url = 'http://localhost:8080'
jsonrpcurl = url + '/jsonrpc'
postdata = '{"jsonrpc": "2.0", "method": "JSONRPC.NotifyAll", "params": {"sender":"Test", "message":"Testing", "data":"Any data"}, "id": "1"}'
request = urllib2.Request(jsonrpcurl, postdata)
request.add_header('Content-Type', 'application/json')
responce = json.loads(urllib2.urlopen(request).read())
print responce
Here seems to be instructions how to send JSON from XBMC plugins

jonib

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Sun Jan 20, 2013 5:20 am
by Lunatixz
Thanks, I'll give it a try

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Tue Jan 29, 2013 11:34 am
by jonib
Lunatixz wrote:Thanks, I'll give it a try
So ware you able to get events from a plugin?

jonib

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Wed Jan 30, 2013 7:22 pm
by gquiring
I had to reloaded my XBMC PC due to a Crucial m4 failure. I am not understanding what I am doing wrong. I installed EG 0.4.1r1610, then configuration, add plugin, XBMC2.

Then I loaded my backup XML file (gq3.xml) and I get unknown plugin XBMC2. I attached a screen cap and my XML file.

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Thu Jan 31, 2013 2:46 pm
by gquiring
I resolved the problem, the GUID changed. Why does app need this since it has a name 'XBMC2'?

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Thu Jan 31, 2013 3:15 pm
by jonib
gquiring wrote:Why does app need this since it has a name 'XBMC2'?
I guess it was added so two plugins that happen to have the same name wouldn't conflict as long as they have unique GUIDs.

jonib

Re: Support for XBMC2 plugin (formerly XBMCRepeat)

Posted: Fri Feb 01, 2013 6:27 pm
by piipes
How i can get xbmc power saving/iddle command to eventghost? I want to run some commands before pc goes to sleep.