If you have not already, we suggest setting your Plex username to something else rather than email which is displayed on your posts in forum. You can change the username at https://app.plex.tv/desktop#!/account
Welcome to our forums! Please take a few moments to read through our Community Guidelines (also conveniently linked in the header at the top of each page). There, you'll find guidelines on conduct, tips on getting the help you may be searching for, and more!

Writing profiles for DLNA devices...

1356712

Comments

  • wouter@lagendijk.wswouter@lagendijk.ws Posts: 3Members, Plex Pass Plex Pass
    Is it possible to create a profile which only exposes audio files for direct play (flac) over DLNA yo certain devices (from the Music library) and nothing else ?

    I want such a profile for playing music on my Marantz NR-1604 receiver that is capable of playing flac gapless over the network. Currently I have to navigate through the menu and choose from Video, Music and Photos (my libraries) but only one is relevant (Music).
  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja
    wslagendijk wrote on July 17 2014, 12:21 PM: »

    Is it possible to create a profile which only exposes audio files for direct play (flac) over DLNA yo certain devices (from the Music library) and nothing else ?

    I want such a profile for playing music on my Marantz NR-1604 receiver that is capable of playing flac gapless over the network. Currently I have to navigate through the menu and choose from Video, Music and Photos (my libraries) but only one is relevant (Music).

    You can tell it that it only can play audio through the profile, however you cannot get rid of the other menus as they are hardcoded into the server, not a profile setting.

  • dlflannerydlflannery Posts: 3Members

    I'm using the Plex App on my Amazon Fire TV with the PMS running on a Win7 PC on the same network.  When I stream an H.264 video file with 1280x720 dimensions it displays without being scaled to the 1920x1080 resolution of my TV, i.e, it has big black borders all around.  I see all kinds of resolution-related settings in both the PMS server and in the Plex App, and for the Fire TV itself.  I've tried a lot of combinations but always get this problem.  I've also tried disabling direct play/streaming. 

    I was wondering if a user profile would fix this but I noticed in the server log that the AFTV is always assigned the "Generic Profile", even though there is a "Android-AFTB.xml" profile in my ...\Resources\Profiles folder and the name in that profile is "Android Fire TV".  As I understand it, the generic profile causes direct play to always be used so that would seem to explain what I'm seeing.

    So I'm wondering if getting this profile assigned to my device isn't the problem?  Any suggestions?  Thanks.

  • webcajuwebcaju Posts: 53Members ✭✭
    Hello I have plex installed on D'Link 320l and use the TV LG47LM6700 there any profile so that I can watch movies Dual audio, I would be able to choose between two languages​​, now I can not change the language of movies in dual audio. 
     
    Thank you all.
  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja
    webcaju wrote on August 18 2014, 12:26 AM: »
    Hello I have plex installed on D'Link 320l and use the TV LG47LM6700 there any profile so that I can watch movies Dual audio, I would be able to choose between two languages​​, now I can not change the language of movies in dual audio. 
     
    Thank you all.

    Attached is my profile.  There are three changes you'll need to make:

    1)

    Rename the file to LG 47LM6700.xml

    2)

    <Client name="LG Blu-Ray LHB336"> to <Client name="LG 47LM6700">

    3)

    <DeviceDescription type="urn:schemas-upnp-org:device:MediaRenderer:1">
        <FriendlyName substring="LG HT DMR-1711" /> <!-- Might need to use device spy to get the actual friendly name for the device -->
        <Manufacturer substring="LG Electronics" />   <!-- should be the same -->
       </DeviceDescription>

    Alternatively you might be able to just comment out the device description section.  I had to use this because during initial requests a user agent was sent, but during file requests the user agent wasn't sent so I needed to identify it from the device description.

    Other than that, transcoding may or may not work.  For my LHB transcoding starts but never plays and I haven't been able to track down why.

  • webcajuwebcaju Posts: 53Members ✭✭
    jmckee wrote on August 18 2014, 1:31 AM: »

    Attached is my profile.  There are three changes you'll need to make:

    1)

    Rename the file to LG 47LM6700.xml

    2)

    <Client name="LG Blu-Ray LHB336"> to <Client name="LG 47LM6700">

    3)

    <DeviceDescription type="urn:schemas-upnp-org:device:MediaRenderer:1">
        <FriendlyName substring="LG HT DMR-1711" /> <!-- Might need to use device spy to get the actual friendly name for the device -->
        <Manufacturer substring="LG Electronics" />   <!-- should be the same -->
       </DeviceDescription>

    Alternatively you might be able to just comment out the device description section.  I had to use this because during initial requests a user agent was sent, but during file requests the user agent wasn't sent so I needed to identify it from the device description.

    Other than that, transcoding may or may not work.  For my LHB transcoding starts but never plays and I haven't been able to track down why.

    Thank you for your help, I have done all changes as indicated, but there remained a doubt. 
     
    After these changes I need to just throw this in the xml profiles folder that it automatically identifies the plex? Or do I need to set it somewhere. 
     
    Thanks again for your great help.
  • dlflannerydlflannery Posts: 3Members
    dlflannery wrote on August 17 2014, 7:02 PM: »

    I'm using the Plex App on my Amazon Fire TV with the PMS running on a Win7 PC on the same network.  When I stream an H.264 video file with 1280x720 dimensions it displays without being scaled to the 1920x1080 resolution of my TV, i.e, it has big black borders all around.  I see all kinds of resolution-related settings in both the PMS server and in the Plex App, and for the Fire TV itself.  I've tried a lot of combinations but always get this problem.  I've also tried disabling direct play/streaming. 

    I was wondering if a user profile would fix this but I noticed in the server log that the AFTV is always assigned the "Generic Profile", even though there is a "Android-AFTB.xml" profile in my ...\Resources\Profiles folder and the name in that profile is "Android Fire TV".  As I understand it, the generic profile causes direct play to always be used so that would seem to explain what I'm seeing.

    So I'm wondering if getting this profile assigned to my device isn't the problem?  Any suggestions?  Thanks.

    Bump -- and additional info:

    Using Device Spy to get required info I created a user profile, "Android.xml", (Since Android is the profile selected in the Fire TV App settings) with an identification section as follows:

      <Identification>
        <DeviceDescription type="urn:dial-multiscreen-org:device:dial:1">
          <ModelName substring="Fire TV"/>
          <FriendlyName substring="David's Fire TV"/>
          <Manufacturer substring="Amazon.com, Inc."/>
        </DeviceDescription>
      </Identification>
     

    At server startup I get the message that the built-in Android profile is being overridden and no error messages.  Yet stil my Fire TV is being mapped to the Generic Profile.  Sure would appreciate some help on this.  It seems like if Plex is going to sell this Fire TV app for $4.99, there shouldn't be so much trouble with it playing videos so they use the entire screen.

  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja
    webcaju wrote on August 18 2014, 1:35 PM: »
    Thank you for your help, I have done all changes as indicated, but there remained a doubt. 
     
    After these changes I need to just throw this in the xml profiles folder that it automatically identifies the plex? Or do I need to set it somewhere. 
     
    Thanks again for your great help.

    You need to place it in the profiles directory where you application data is stored.  On windows it is located at:

    C:\users\<user name>\appdata\local\plex media server\profiles

    *You will need to create the profiles folder in this location

  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja
    dlflannery wrote on August 18 2014, 8:15 PM: »

    Bump -- and additional info:

    Using Device Spy to get required info I created a user profile, "Android.xml", (Since Android is the profile selected in the Fire TV App settings) with an identification section as follows:

      <Identification>
        <DeviceDescription type="urn:dial-multiscreen-org:device:dial:1">
          <ModelName substring="Fire TV"/>
          <FriendlyName substring="David's Fire TV"/>
          <Manufacturer substring="Amazon.com, Inc."/>
        </DeviceDescription>
      </Identification>
     

    At server startup I get the message that the built-in Android profile is being overridden and no error messages.  Yet stil my Fire TV is being mapped to the Generic Profile.  Sure would appreciate some help on this.  It seems like if Plex is going to sell this Fire TV app for $4.99, there shouldn't be so much trouble with it playing videos so they use the entire screen.

    If you're using the plex app on the Fire TV, then you are not using DLNA and modifying/creating profiles will not change this.  It might be better if you create a new topic on the issue rather then using the profile writing guide.

    With that being said, what is your plex media server log say when you are attempting to play one of these files?  Typically, the video transcode to the same resolution as the original and then the device will choose how to display that.  IE with the blackbars, or zoomed to full screen.

  • webcajuwebcaju Posts: 53Members ✭✭
    jmckee wrote on August 19 2014, 12:05 AM: »

    You need to place it in the profiles directory where you application data is stored.  On windows it is located at:

    C:\users\<user name>\appdata\local\plex media server\profiles

    *You will need to create the profiles folder in this location

    Okay, do I have it installed on D'link 320l if I saved in that directory:

    /mnt/HD/HD_a2/ffp/lib/plexmediaserver/Resources/Profiles

    I do not know if this would be the correct directory.

  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja
    webcaju wrote on August 19 2014, 12:42 AM: »

    Okay, do I have it installed on D'link 320l if I saved in that directory:

    /mnt/HD/HD_a2/ffp/lib/plexmediaserver/Resources/Profiles

    I do not know if this would be the correct directory.

    I can't tell you for sure as I use windows, but if that is the directory with the default system profiles then no that is the wrong directory.  You will need to locate the plex folder with the logs directory, you will need to create the profiles directory there.

    https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files

    That article has the most common locations for the logs, so if your able to find the Plex Media Server location in there you should be on the right track.

  • webcajuwebcaju Posts: 53Members ✭✭

    I believe I found this way:

    /mnt/HD/HD_a2/ffp/programs/plex/lib/Plex Media Server/Logs/

    Should I create the profiles directory in the logs folder or inside the Plex Media Server 
     
    If you do not know without problems'm researching but have not found anything yet. 
     
    Thank you.
  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja
    webcaju wrote on August 20 2014, 4:13 PM: »

    I believe I found this way:

    /mnt/HD/HD_a2/ffp/programs/plex/lib/Plex Media Server/Logs/

    Should I create the profiles directory in the logs folder or inside the Plex Media Server 
     
    If you do not know without problems'm researching but have not found anything yet. 
     
    Thank you.

    Inside the Plex Media Server Folder

  • awvc1@hotmail.comawvc1@hotmail.com Posts: 20Members

    I've tried to get this working on osx - i've tried every possible permutation of the various suggestions here. People have asked definitively for the location user profiles on OSX and it doesn' seem to be anything said here in this thread. What should the full path be on OSX?

    its not:

    /Users/XXXX/Library/Application Support/Plex Media Server

    /Users/XXXX/Library/Application Support/Plex Media Server/profiles

    /Users/XXXX/Library/Application Support/Plex Media Server/Profiles

    /Users/XXXX/Library/Application Support/Plex Media Server/Resources/profiles

    /Users/XXXX/Library/Application Support/Plex Media Server/Resources/Profiles

     

    A plex employee said an address with 'don't quote me on it' - we need to be able to quote you on it? You are the only ones that know this, not us?

  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja
    edited August 2014

    https://forums.plex.tv/topic/73702-writing-profiles-for-dlna-devices/page-2#entry501129

    That person is correct it is:

    ~/Library/Application Support/Plex Media Server/Profiles

    The directory above it should have your logs and plugins folder.  You should have to create a profiles directory.

    I guess the bigger question is why do you think this directory is wrong?

  • awvc1@hotmail.comawvc1@hotmail.com Posts: 20Members
    jmckee wrote on August 21 2014, 2:11 PM: »

    https://forums.plex.tv/topic/73702-writing-profiles-for-dlna-devices/page-2#entry501129

    That person is correct it is:

    ~/Library/Application Support/Plex Media Server/Profiles

    The directory above it should have your logs and plugins folder.  You should have to create a profiles directory.

    I guess the bigger question is why do you think this directory is wrong?

    because it doesn't work and still says it can't find the profile name in the server.log

  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja

    If you're seeing a message saying it can't find the profile name then something else is wrong.  The only difference between with the profiles and without is this:

    With Profiles:

    Aug 21, 2014 15:51:23:647 [10116] DEBUG - MyPlex: https://plex.tv/
    Aug 21, 2014 15:51:23:677 [10116] DEBUG - Reading system DLNA client profiles
    Aug 21, 2014 15:51:23:700 [10116] DEBUG - Overriding PlayStation 3 profile with user client profile
    Aug 21, 2014 15:51:23:712 [10116] DEBUG - Reading user client profile LG Blu-Ray LHB336
    Aug 21, 2014 15:51:23:713 [10116] DEBUG - Reading user client profile Panasonic G30 Series
    Aug 21, 2014 15:51:23:713 [10116] DEBUG - Reading user client profile Panasonic Viera G30
    Aug 21, 2014 15:51:23:714 [10116] DEBUG - Reading user client profile Sony 4K 2013
    Aug 21, 2014 15:51:23:715 [10116] DEBUG - Reading user client profile Sony Bravia 2014
    Aug 21, 2014 15:51:23:715 [10116] DEBUG - Read 21 DLNA client profiles

    Without profiles:

    Aug 22, 2014 00:39:01:097 [7948] DEBUG - MyPlex: https://plex.tv/

    Aug 22, 2014 00:39:01:127 [7948] DEBUG - Reading system DLNA client profiles
    Aug 22, 2014 00:39:01:164 [7948] DEBUG - Read 16 DLNA client profiles

  • awvc1@hotmail.comawvc1@hotmail.com Posts: 20Members
    jmckee wrote on August 21 2014, 3:17 PM: »

    If you're seeing a message saying it can't find the profile name then something else is wrong.  The only difference between with the profiles and without is this:

    With Profiles:

    Without profiles:

    thanks for the reply but that doesn't really help.

    Aug 21, 2014 12:47:39 [0x104df1000] ERROR - Unable to find client profile for device; platform=BlackBerry10, platformVersion=, device=, model=

    Aug 21, 2014 12:47:39 [0x104df1000] ERROR - [TranscodeUniversalRequest] Unable to find a matching profile

     

    is the error I get.  I'm trying to write a profile for a BlackBerry10 phone, and this is what I get in the error log.

     

    Any ideas why please? Documentation on this (other than what I can glean from this and numerous other out of date or incorrect threads) seems unavailable unless I'm wrong? Watching server logs for clues on how to send the right parameters to an end point is the only official advice I've been given so far, which feels more like reverse engineering or hacking. Where is the best documentation on this please?

  • jmckeejmckee Posts: 5,012Members, Plex Pass, Plex Ninja Plex Ninja

    What does your profile look like?

    If I had to guess I would say the name of your xml isn't matching the Client name field in your profile.

    IE for my LG:

    LG Blu-Ray LHB336.xml

    <Client name="LG Blu-Ray LHB336">

    As for documentation, profile writing is an advanced feature and there isn't a lot of documentation.  The guide here hasn't really been updated and a few of the settings and options arn't even valid anymore.  The easiest way to start out is to copy a profile from a work device that is close and modify the profile to match what you need.

  • awvc1@hotmail.comawvc1@hotmail.com Posts: 20Members
    jmckee wrote on August 22 2014, 12:35 AM: »

    What does your profile look like?

    If I had to guess I would say the name of your xml isn't matching the Client name field in your profile.

    IE for my LG:

    LG Blu-Ray LHB336.xml

    <Client name="LG Blu-Ray LHB336">

    As for documentation, profile writing is an advanced feature and there isn't a lot of documentation.  The guide here hasn't really been updated and a few of the settings and options arn't even valid anymore.  The easiest way to start out is to copy a profile from a work device that is close and modify the profile to match what you need.

    HI .

    cheers again for the help. The xml is so far a direct copy of the android profile with the client name changed to the same as the file name, and the name passed in the url parameter:

    <?xml version="1.0" encoding="utf-8"?>

    <Client name="BlackBerry10">

      <!-- Author: Plex Inc. -->

      <TranscodeTargets>

        <VideoProfile protocol="hls" container="mpegts" codec="h264" audioCodec="a

    ac" context="streaming">

          <Setting name="VideoEncodeFlags" value="-x264opts cabac=0" />

          <Setting name="SubtitleSize" value="100" />

        </VideoProfile>

        <VideoProfile container="mp4" codec="h264" audioCodec="aac" context="all">

          <Setting name="VideoEncodeFlags" value="-x264opts cabac=0" />

        </VideoProfile>

        <MusicProfile container="mp3" codec="mp3" />

        <PhotoProfile container="jpeg" />

      </TranscodeTargets>

      <DirectPlayProfiles>

        <VideoProfile container="mp4" codec="h264,mpeg4" audioCodec="aac" />

        <MusicProfile container="mp4" codec="aac" />

        <MusicProfile container="mp3" codec="mp3" />

        <MusicProfile container="flac" codec="flac" />

        <MusicProfile container="ogg" codec="vorbis" />

        <PhotoProfile container="jpeg,gif,bmp,png" />

      </DirectPlayProfiles>

      <ContainerProfiles>

        <VideoContainer name="mp4">

        <Limitations>

            <Match name="part.optimizedForStreaming" value="1" />

          </Limitations>

        </VideoContainer>

      </ContainerProfiles>

      <CodecProfiles>

        <VideoCodec name="*">

          <Limitations>

            <UpperBound name="video.width" value="1920" />

            <UpperBound name="video.height" value="1080" />

            <NotMatch name="video.anamorphic" value="1" isRequired="false" />

            <NotMatch name="video.hasScalingMatrix" value="1" isRequired="false" /

    >

            <UpperBound name="video.bitDepth" value="8" isRequired="false" />

          </Limitations>

        </VideoCodec>

        <VideoAudioCodec name="aac">

          <Limitations>

            <UpperBound name="audio.channels" value="2" />

          </Limitations>

        </VideoAudioCodec>

        <MusicCodec name="aac">

          <Limitations>

            <UpperBound name="audio.channels" value="2" />

          </Limitations>

        </MusicCodec>

        <MusicCodec name="mp3">

          <Limitations>

            <UpperBound name="audio.bitrate" value="320" />

            <UpperBound name="audio.channels" value="2" />

          </Limitations>

        </MusicCodec>

      </CodecProfiles>

    </Client>

Sign In or Register to comment.