need help with playlist.m3u
#1
Hi. I need help getting a playlist to work. I am on v18 and know about posting and have gotten my old get statements to work.
at present ,
i goto home screen -  {"jsonrpc":"2.0","method":"Input.Home","id":1}"
clearing the playlist - {"jsonrpc":"2.0","id":1,"method":"Playlist.Clear","params":{"playlistid":1}}
i then add the m3u file - {"jsonrpc":"2.0","method":"Playlist.Add","params": {"playlistid": 1 ,"item": {"file": " & ""smb://PlayList.m3u""} }, "id": 1 }
then i try to play m3u - {"jsonrpc":"2.0",""d":1,"method":"Player.Open","params":{"item":{""playlistid":1}}}

after each line i get - {"id":1,"jsonrpc":"2.0","result":"OK"}

but nothing plays. i even browse to the m3u file in a folder and try to manually play this file but it does not work.

the contents of the m3u are - smb://folder1/folder2/Movies/Action/moviename/moviename.mp4

can any advise why this wont play any more and give 4 x OK's

thanks
Reply
#2
(2019-02-14, 22:40)k_zeon Wrote: Hi. I need help getting a playlist to work. I am on v18 and know about posting and have gotten my old get statements to work.
at present ,
i goto home screen -  {"jsonrpc":"2.0","method":"Input.Home","id":1}"
clearing the playlist - {"jsonrpc":"2.0","id":1,"method":"Playlist.Clear","params":{"playlistid":1}}
i then add the m3u file - {"jsonrpc":"2.0","method":"Playlist.Add","params": {"playlistid": 1 ,"item": {"file": " & ""smb://PlayList.m3u""} }, "id": 1 }
then i try to play m3u - {"jsonrpc":"2.0",""d":1,"method":"Player.Open","params":{"item":{""playlistid":1}}}

after each line i get - {"id":1,"jsonrpc":"2.0","result":"OK"}

but nothing plays. i even browse to the m3u file in a folder and try to manually play this file but it does not work.

the contents of the m3u are - smb://folder1/folder2/Movies/Action/moviename/moviename.mp4

can any advise why this wont play any more and give 4 x OK's

thanks
Please post a log to https://paste.kodi.tv/
what method are you using to access json, internal Kodi API, WebSocket?
BTW if I'm to understand the syntax above, you are trying to pass a m3u payload to "Playlist.Add"? If that's the case I don't believe this will work. skip this and load the m3u directly with "Player.Open".
Image Lunatixz - Kodi / Beta repository
Image PseudoTV - Forum | Website | Youtube | Help?
Reply
#3
(2019-02-14, 23:43)Lunatixz Wrote:
(2019-02-14, 22:40)k_zeon Wrote: Hi. I need help getting a playlist to work. I am on v18 and know about posting and have gotten my old get statements to work.
at present ,
i goto home screen -  {"jsonrpc":"2.0","method":"Input.Home","id":1}"
clearing the playlist - {"jsonrpc":"2.0","id":1,"method":"Playlist.Clear","params":{"playlistid":1}}
i then add the m3u file - {"jsonrpc":"2.0","method":"Playlist.Add","params": {"playlistid": 1 ,"item": {"file": " & ""smb://PlayList.m3u""} }, "id": 1 }
then i try to play m3u - {"jsonrpc":"2.0",""d":1,"method":"Player.Open","params":{"item":{""playlistid":1}}}

after each line i get - {"id":1,"jsonrpc":"2.0","result":"OK"}

but nothing plays. i even browse to the m3u file in a folder and try to manually play this file but it does not work.

the contents of the m3u are - smb://folder1/folder2/Movies/Action/moviename/moviename.mp4

can any advise why this wont play any more and give 4 x OK's

thanks
Please post a log to https://paste.kodi.tv/
what method are you using to access json, internal Kodi API, WebSocket?
BTW if I'm to understand the syntax above, you are trying to pass a m3u payload to "Playlist.Add"? If that's the case I don't believe this will work. skip this and load the m3u directly with "Player.Open". 
Hi, thanks for reply. I used VB6 app that i created to issue commands .

    Dim myMSXML
    Set myMSXML = CreateObject("Microsoft.XmlHttp")
    myMSXML.Open "POST", URL, False
    myMSXML.SetRequestHeader "Content-Type", "application/json"

    myMSXML.sEnd JsonRequest
    RunKodiCommand = myMSXML.ResponseText

the above json request used to work fine in ve 17.6.

I will try  {"jsonrpc":"2.0",""d":1,"method":"Player.Open","params":{"item":{"file": " & ""smb://PlayList.m3u""}}}

would this be the correct format
Reply
#4
also , why can i not use playlist.add anymore. some videos i want to play come in 2 parts.
Reply
#5
(2019-02-15, 00:43)k_zeon Wrote: also , why can i not use playlist.add anymore. some videos i want to play come in 2 parts.
 its unorthodox to call a playlist in a playlist... supprised it worked at all!
If you have a stacked video you'd use the stack:// protocol in the "Playlist.Add" item entry... https://forum.kodi.tv/showthread.php?tid...pid2478915
Image Lunatixz - Kodi / Beta repository
Image PseudoTV - Forum | Website | Youtube | Help?
Reply
#6
ok tried to use Player.Open and it did not work. I think there may be an issue with the m3u file

i just create a basic text file with smb://nasdevice/media/folder/movie.mpg  but even if i click this file from kodi to play
it does not.

Are there new settings in Kodi that are restricting smb. or do i need to put something else in the m3u file.

Maybe all the json request i make are working , its just not playing the files properly.

tks
Reply
#7
changed my m3u file to just the movename.mpg  and in kodi i can run this m3u file and the movie plays.

if i use :
"{""jsonrpc"":""2.0"",""method"":""Playlist.Add"",""params"": {""playlistid"": 1 ,""item"": {""file"": " & """" & "smb://Qnap2/Medfia/PlayList.m3u" & """} }, ""id"": 1 }"

it does not do anything and i do get the OK response.

has this broken in ver 18
Reply
#8
The OK response just means that the JSON request you made was syntactically correct and has been passed to Kodi, it does not mean the operation requested was successful or always possible.

It is most likely that you are having an issue with SMB (that has changed inv18) than with JSON, but without a debug log it is impossible to know.

AFAIK playlist within playlists is a supported feature, certainly for music although I have not tried with video.
Reply
#9
so, after a lot of trial and error and searching the internet, i have found that even if password.xml contains

 <path>
        <from pathversion="1">smb://QNAP2/folder/folder</from>
        <to pathversion="1">smb://user:pass@QNAP2/folder/folder/</to>
    </path>

it is not passed through to the json request.

this does not  work
{"jsonrpc":"2.0","id":"1","method":"Player.Open","params":{"item":{"file":"smb://Qnap2/folder/folder/Action/moviename/PlayList.m3u"}}}

this does
{"jsonrpc":"2.0","id":"1","method":"Player.Open","params":{"item":{"file":"smb://user:pass@Qnap2/folder/folder/Action/moviename/PlayList.m3u"}}}

seems i have to pass the user name and password to the Nas directly

is this supposed to be this way.

please advise
Reply
#10
please see snippet from log

20:38:15.966 T:140271051475072   ERROR: Playlist Player: skipping unplayable item: 0, path [smb://Qnap2/folder/Movies/Action/folder/PlayList.m3u]
20:39:50.795 T:140271051475072  NOTICE: Samba is idle. Closing the remaining connections
20:40:37.852 T:140271051475072  NOTICE: VideoPlayer::OpenFile: smb://USERNAMETongueASSWORD@Qnap2/folder/Movies/Action/folder/PlayList.m3u

all i did was add username & password to json as above
Reply
#11
anybody......
Reply
#12
Hi. if anyone on team kodi can answer this question.

when POSTing  a json-rpc from a windows PC ( win7pro 64bit ) to play a file on Kodi 18 , do i need to include the username & password for the device i am connecting too.

Seems without htis it does not play, just adding UseTongueass to json it works.?

as i said in previous post, my passwords.xml does contain a substitution.
I thought that this should be used for all actions and should not have to incluse username & password

many thanks
Reply

Logout Mark Read Team Forum Stats Members Help
need help with playlist.m3u0