DLNA uri syntax with SetPlayContent

  • Hi,

    I am trying to play music from my DLNA server using SetPlayContent.
    My json file:


    This request returns the error code 3.

    The url_of_file is good (, I can curl or wget the file. So I think the problem comes from the way I use the uri parameter.

    I've also tried the method described : here, but my DLNA server does not have service named AVTransport:1.

    Can you tell me what I'm doing wrong ?


  • DeveloperWorld

    Hi @Kaawin,
    Using the setPlayContent to play DLNA content is not recommended I have had mixed results with it and lot of frustration...

    It is not your media server that needs to have the AVTransportservice that is for the sony receiver or speaker you want to play the music on.
    To make it easier for you to get the correct information your media server should hopefully support the service ContentDirectory. Otherwise you have to fill in the info using the provided examples, it is easy to get them wrong and the error messages you get (if you get any) is not that helpful.

    Unfortunately the code examples on developer world have some issues, so it is better to look here https://github.com/sonydevworld/audio_control_api_examples/tree/master/DLNA for examples.

    Hope this helped, and good luck!!!