Announcement

Collapse
No announcement yet.

HSTouch Clients and DLNA Manager

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    HSTouch Clients and DLNA Manager

    Didn't know this was going to be as long so a short version is, is there a script I can run as an event on track change to poll the DLNA Manager to update the status text labels in the clients of HSTouch? (Read below for more in depth)


    Forgive me if this is a simple script writing exercise but I am fairly new to the home automation scene.

    I am using JRiver as the "DLNA Server" and have 4 zones installed to see if I can get it to do what I want before finishing install.

    In HSTouch Designer, I created three text labels with status pointing to "artist name", "album", and "title track". I also have buttons created for "next", "play", "stop", etc...DLNA Manager used for those actions.

    When I run the clients everything starts up and the labels are created correctly per current song. If I press "next" the labels change to next song selected, no problems. The problem starts when I let the song end and the next song is played from playlist. The labels remain as the same as the previous song instead of updating. Granted almost as the new song is ending, the labels are correctly populated but by that time the next song is playing and is not matching the labels for current song.

    Question is, is there a script I can add as an event to poll the DLNA Manager to update the labels say for a track change? I know a little bit about the polldevice command but I am not sure what the dim variables are I should be polling for the labels.

    Thanks for any feedback.

    #2
    Originally posted by olag00 View Post
    Didn't know this was going to be as long so a short version is, is there a script I can run as an event on track change to poll the DLNA Manager to update the status text labels in the clients of HSTouch? (Read below for more in depth)


    Forgive me if this is a simple script writing exercise but I am fairly new to the home automation scene.

    I am using JRiver as the "DLNA Server" and have 4 zones installed to see if I can get it to do what I want before finishing install.

    In HSTouch Designer, I created three text labels with status pointing to "artist name", "album", and "title track". I also have buttons created for "next", "play", "stop", etc...DLNA Manager used for those actions.

    When I run the clients everything starts up and the labels are created correctly per current song. If I press "next" the labels change to next song selected, no problems. The problem starts when I let the song end and the next song is played from playlist. The labels remain as the same as the previous song instead of updating. Granted almost as the new song is ending, the labels are correctly populated but by that time the next song is playing and is not matching the labels for current song.

    Question is, is there a script I can add as an event to poll the DLNA Manager to update the labels say for a track change? I know a little bit about the polldevice command but I am not sure what the dim variables are I should be polling for the labels.

    Thanks for any feedback.
    What are you using as a DLNA renderer (player)? This plugin only has events for players not servers and they should update properly unless there is an issue with the DLNA implementation on that renderer or a bug in the plugin. Do you mind explain who is doing what? Screenshots and debug logs always help explain.

    Cheers,

    Dirk

    Comment


      #3
      Thanks for getting back to me. I just got to work and I don't have homeseer setup for remote viewing yet so I wont be able to get the logs until this evening.

      I just bought two 7" Zeepad Android tablets to run as Android Touch Clients. I designed audio and video screens to control the TVs as well as the whole home audio ceiling speakers.

      I am new to this plugin but I would say the renderer is JRiver MC located on the computer (Win7/64bit) where homeseer is installed. This computer is where I have multiple USB soundcards connected, each with their own speaker client. For instance, the gameroom is homeserver:gameroom and study would be homeserver:study, etc.

      On the same computer is where I have JRiver setup as media server. I believe the name is JRiver (Generic DLNA server).

      The below is a sketch I made in Paint of my audio screen:



      The track, artist, and album information are all correct if I press PLAY from the tablet. It also displays the correct information if I press NEXT. The only problem is when I let the songs go and finish on their own. The next song starts from the play list but the android tablets are showing the previous song. It is almost like the android tablets are 1 - 2 songs behind but as soon as I press Next, the tablets update to the correct song information.

      If none of this information helps I will post actual screen shots of settings and actions when I get home. Thanks again.

      Comment


        #4
        Ok. Just to get this out of the way, yes it was brutal listening to the songs that happened to be on the playlist as I was doing this.
        Here are my settings for DLNA Manager:









        All "zones" have these settings.












        http://www.dropbox.com/s/1714olnd4sj...0to%207_36.txt

        Comment


          #5
          Originally posted by olag00 View Post
          Ok. Just to get this out of the way, yes it was brutal listening to the songs that happened to be on the playlist as I was doing this.


          That is all I have. Hopefully you can decipher it all out.
          Thanks.
          Well this was probably the best documented posting I ever received.

          I'm going to assume you were playing a playlist of some sort on the player, directly selected from some other control application.

          I'm going to google JRiver next but what version have you installed and is it the latest? From looking at your logs, my first reaction is that there is something wrong with their DLNA implementation (which unfortunately I have seen a lot). I might install it and see what I can do. But this is what I retrieve from your log file and is what the player reports:

          1/29/2013 6:59:58 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = How Do I Live? [Mr. Mig Remix- Dance Radio Edit] [Extended Mix]
          1/29/2013 6:59:58 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = LeAnn Rimes

          1/29/2013 6:59:58 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = Some Kind of Miracle
          1/29/2013 6:59:58 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Kelly Clarkson

          1/29/2013 7:03:26 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = Some Kind of Miracle
          1/29/2013 7:03:26 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Kelly Clarkson

          1/29/2013 7:03:38 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = Love's the Only House
          1/29/2013 7:03:38 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Martina McBride

          1/29/2013 7:08:33 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = Love's the Only House
          1/29/2013 7:08:33 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Martina McBride

          1/29/2013 7:12:41 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = Beautiful Disaster
          1/29/2013 7:12:41 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Kelly Clarkson

          1/29/2013 7:13:58 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = Sunrise
          1/29/2013 7:13:58 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Jones, Norah

          1/29/2013 7:13:58 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = The Trouble With Love Is
          1/29/2013 7:13:58 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Kelly Clarkson

          1/29/2013 7:17:28 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = The Trouble With Love Is
          1/29/2013 7:17:28 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Kelly Clarkson

          1/29/2013 7:17:28 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = The Trouble With Love Is
          1/29/2013 7:17:28 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Kelly Clarkson

          1/29/2013 7:21:45 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = How Do I Live? [Film Mix]
          1/29/2013 7:21:45 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = LeAnn Rimes

          1/29/2013 7:21:46 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = How Do I Live? [Film Mix]
          1/29/2013 7:21:46 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = LeAnn Rimes

          1/29/2013 7:23:38 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Title) = Fantasy
          1/29/2013 7:23:38 PM ~!~DLNA Manager~!~TransportStateChange for UPnPDevice = Homeserver: Gameroom received (Artist) = Mariah Carey


          As you can see, the player is reporting the wrong track info, while doing that, I noted the player status being reported quite inconsistent as well.

          Dirk

          Comment


            #6
            I installed JRiver v18.0.106 just now and see the same behavior. After a few tracks, I suddenly see the player reporting a player state from playing to transitioning and after that the events are one track behind.

            Not sure whether you are a member on their forum but you could log a complain there that the DLNA AVTransport events contain the wrong track information. I see them being sent a few seconds before the end of the track but instead of having the next track info in them, it contains the current track info and that's why you have either no update (that's when it happens the first time) or it shows a track behind.

            Dirk.

            Comment


              #7
              Submitted post on JRiver forum (http://yabb.jriver.com/interact/index.php?topic=77803.0)

              Let's see what happens.

              Dirk

              Comment


                #8
                Excellent. Thanks for the help. I will watch that thread as well.

                Comment


                  #9
                  Originally posted by olag00 View Post
                  Excellent. Thanks for the help. I will watch that thread as well.
                  Perhaps something to try to confirm this problem as JRiver ....

                  You have more than one instance of JRiver player running, correct?

                  If you set the option to have the JRiver app as "DLNA Controller" (Tools>Options>Media Network>Advanced), I would assume that you can play something on lets say player one, then use player two but just click on the "Playing Now" for player one. I would expect you to see this out of sequence problem as well.

                  Dirk

                  Comment


                    #10
                    Originally posted by dcorsus View Post
                    Perhaps something to try to confirm this problem as JRiver ....

                    You have more than one instance of JRiver player running, correct?

                    If you set the option to have the JRiver app as "DLNA Controller" (Tools>Options>Media Network>Advanced), I would assume that you can play something on lets say player one, then use player two but just click on the "Playing Now" for player one. I would expect you to see this out of sequence problem as well.

                    Dirk

                    Actually that is the way I already have it. So it does produce same problem.

                    Comment


                      #11
                      Originally posted by olag00 View Post
                      Actually that is the way I already have it. So it does produce same problem.
                      What's I thought. I'll add it to the ticket so it would be easy for the JRiver people to replicate and convince them there is a problem. Currently trying some work arounds

                      Dirk

                      Comment


                        #12
                        Just posted a new beta .39 with a workaround. Can you try it out and let me know it does its thing.

                        Thanks

                        Dirk

                        Comment


                          #13
                          Great job! For now it is working. It updates after about 5-10 seconds and in my eyes that is fixed. I tested in a couple of different zones and no problems. I will let you know if it starts happening again.

                          FYI, I found out you don't have to wait for the track to play out. You can just drag the progress tracker towards the end of the song and then let it finish. Saves a lot of test time.

                          Again thanks for the fix!

                          Comment


                            #14
                            Originally posted by olag00 View Post
                            Great job! For now it is working. It updates after about 5-10 seconds and in my eyes that is fixed. I tested in a couple of different zones and no problems. I will let you know if it starts happening again.

                            FYI, I found out you don't have to wait for the track to play out. You can just drag the progress tracker towards the end of the song and then let it finish. Saves a lot of test time.

                            Again thanks for the fix!
                            The "workaround" which doubles as a safety valve, is designed to request the trackinformation when the trackduration has been exceeded by 5 seconds. I was using the Progress tracker slider as well and did notice yet another problem with JRMC, when you change the trackposition, the player must inform its DLNA controllers so they can update their track position as well. JRMC didn't generate any events . The reason it works is because about 10 seconds before the track ends, an event is generated and that updates the current track position. Other DLNA players do this as well but they use it to announce the next track info, JRMC is again not doing that either

                            That makes it at least 3 shortcomings seen in 2 hours of testing. Currently doing some tests on the JRMC server functions, see how robust they are.

                            Dirk

                            Comment


                              #15
                              Well atleast i have around 20 more days before I have to decide if I want to keep using JRiver. The plus side for JRiver is I can play different songs in different rooms with their media center. Essentially assign a specific usb soundcard to a specific zone. JRiver was the first server I tried due to this capability. I will look around and see if there are more out there allowing me to do this. I don't want to go the Russound, Niles, or other pre engineered route. I am looking for the cheaper DIY approach.

                              Comment

                              Working...
                              X