Posts: 111
Joined: Dec 2008
Reputation:
0
Also, what's the difference between AudioPlayer.SkipNext vs AudioPlaylist.SkipNext?
It seems there are lot of controls which are common between AudioPlayer and AudioPlaylist. Are they different in terms of what they do or they can be use interchangabely? Also, Do I need to use controls in VideoPlayer if I want to control video playback and AudioPlayer when playing audio file? Seems they should control the current media playback irrespective of what kind of media is playing.
Does it make sense? Can somebody please clarify?
thanks
Posts: 538
Joined: Sep 2010
Reputation:
21
can we toggle something in the library as watched/unwatched with json at this time?
Posts: 703
Joined: May 2009
Reputation:
2
erhnam
Team-XBMC Live Developer
Posts: 703
topfs2 or anyone else?
Is it possible to use json rpc to navigate through XBMC?
Posts: 4,549
Joined: Dec 2007
Reputation:
17
topfs2
Team-Kodi Developer
Posts: 4,549
No real difference between AudioPlayer.SkipNext and AudioPlaylist.SkipNext. One of those should probably go.
Cannot toggle watched status as of now.
Cannot navigate the GUI via jsonrpc, waiting on input abstraction redesign before adding it in jsonrpc (its a mess now for other input stuff so don't want to clutter jsonrpc with it).
If you have problems please read
this before posting
Always read the
XBMC online-manual,
FAQ and
search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the
forum rules.
For troubleshooting and bug reporting please make sure you
read this first.
"Well Im gonna download the code and look at it a bit but I'm certainly not a really good C/C++ programer but I'd help as much as I can, I mostly write in C#."
Posts: 3,077
Joined: Jun 2009
Since json is making progress i tried again to go with it
It seems there's problem with playlist.getItems as depending on how you start the media you loose access to all database informations.
If you start the media from library it allmost all times works, but if you start the file from file mode (or with the httpapi with play(filename)) it don't works, even if the player shows the informations correctly and the httpapi with getnowplaying gives correct informations too.
And i reiterate my request that was discussed some times ago and mostly accepted, to getback some kind of thing similar to GetNowPlaying to avoid hamering XBMC with request (4 request per sec to get current player, volume , progress and media informations) that's a little too much
Tolriq.
Posts: 4
Joined: Oct 2010
Reputation:
0
is it already possible, to retrieve the fanart of a specific movie?
Posts: 131
Joined: May 2010
Reputation:
0
I have spent all day trying to get this to work. I have been through the full thread and most of the auxiliary threads. I am running the LiveFreak version of XBMC Dharma Beta2.
If I use the http interface (which I do a lot with) it works fine
NOTE: In the examples of send and receive the string (CR) and the string (LF) represent the single corresponding bytes. I am sending to ip:8080 and make no changes to the basic programs that write to and receive from the ports.
First an example using the HTTP API:
SEND: GET /xbmcCmds/xbmcHttp?command=Action(3)(CR)(LF)(CR)(LF)
RCVD: HTTP/1.1 200 OK(CR)(LF)Content-Length: 22(CR)(LF)Date: Sat, 09 Oct 2010 23:09:30 GMT(CR)(LF)(CR)(LF)<html>(LF)<li>OK(LF)</html>(LF)
I tried this and got no where:
SEND: POST /jsonrpc/ HTTP/1.1(CR)(LF)Content-Length: 57(CR)(LF)HOST: 192.168.2.202:80(CR)(LF)(CR)(LF){"jsonrpc": "2.0", "method": "System.Shutdown", "id": 1}(CR)(LF)(CR)(LF)
RCVD: HTTP/1.1 404 Not Found(CR)(LF)Content-Length: 82(CR)(LF)Date: Sat, 09 Oct 2010 23:09:06 GMT(CR)(LF)(CR)(LF)<html><head><title>File not found</title></head><body>File not found</body></html>HTTP/1.1 404 Not Found(CR)(LF)Content-Length: 131(CR)(LF)Date: Sat, 09 Oct 2010 23:09:06 GMT(CR)(LF)(CR)(LF)<html><head><title>Not Supported</title></head><body>The method you are trying to use is not supported by this server</body></html>
If I remove the "/" after the POST /jsonrpc
SEND(130): POST /jsonrpc HTTP/1.1(CR)(LF)Content-Length: 56(CR)(LF)HOST: 192.168.2.202:80(CR)(LF)(CR)(LF){"jsonrpc": "2.0", "method": "System.Suspend", "id": 1}(CR)(LF)(CR)(LF)
Produces no reply from the server
I must be doing something very basic incorrectly. I have tried all of the System methods and the Version Method all with the same results.
I also tried using raw TCP to the port 9090 but that port is not opened. Is that the correct port or must I initialize it somewhere in XBMC?
I assume if I use the raw port I would just send
/jsonrpc {"jsonrpc": "2.0" . . . "id": 1}
Any help that will allow me to get started would be greatly appreciated.
Posts: 153
Joined: Mar 2006
Reputation:
13
jonib
Senior Member
Posts: 153
You seem to use port 80 with the jsonrpc, but use port 8080 with httpapi. You should use the same port for both.
jonib
XBMC2, EventGhost plugin.
Posts: 4,549
Joined: Dec 2007
Reputation:
17
topfs2
Team-Kodi Developer
Posts: 4,549
What jonib said and for 9090 use you need to enable it in xbmc, its called "Allow external applications to control xbmc" or something close to that.
If you have problems please read
this before posting
Always read the
XBMC online-manual,
FAQ and
search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the
forum rules.
For troubleshooting and bug reporting please make sure you
read this first.
"Well Im gonna download the code and look at it a bit but I'm certainly not a really good C/C++ programer but I'd help as much as I can, I mostly write in C#."
Posts: 131
Joined: May 2010
Reputation:
0
Thanks for the help guys. I pulled the Host clause and content length clause and everything started working through the HTTP api. I then enabled external applications and everything started working through the raw TCPIP Socket. I believe I will stick with the RAW TCP socket unless someone advises me otherwise. All the system commands do what they are supposed to and the version request returns 1.0 as the result formatted in JSON.
What I am doing is building an XBMC control system for the Philips Pronto PRO Remote. I will be using both the HTTP API for such things as sendkeys and the raw interface for JSON formatted things. My current endeavor is strictly control.
The only remaining problem with Dharma is that I can't get it to Wake on LAN and have posted that issue in the general section. My system dual boots between Camelot and Dharma for testing and evaluation. Camelot handles WOL fine, Dharma does not. But this is not a topic for here and I have posted a help request in what I think is the proper place.
Posts: 4,549
Joined: Dec 2007
Reputation:
17
topfs2
Team-Kodi Developer
Posts: 4,549
Does not matter which of the interfaces you use, its just a preference.
The tcp has the ability to get announcements, which might be very useful depending on the control. The http can download files which is needed for some remotes. The http can be password protected, although extremely crappy http base64 one (standard http one) but atleast its something. There will hopefully be an ssl encrypted option at some point.
If you have problems please read
this before posting
Always read the
XBMC online-manual,
FAQ and
search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the
forum rules.
For troubleshooting and bug reporting please make sure you
read this first.
"Well Im gonna download the code and look at it a bit but I'm certainly not a really good C/C++ programer but I'd help as much as I can, I mostly write in C#."
Posts: 131
Joined: May 2010
Reputation:
0
I have seen several references to the document that describes the JSON methods that have been implemented to date. The one I have is dated feb 15 2010. Is that the latest one? If not could some one post a URL to the latest one? I have ssen instructions on how to get to it but all I ever end up with is a blank web page or a web page not found
TIA