Philips TV (2016+) Binding

this is what comes back in my logs after turning on the tv, and pressing the netflix button on the remote.

18-Dec-2019 09:20:02.010 [DEBUG] [v.internal.discovery.PhilipsTvDiscoveryParticipant] - Device found: Philips TV DMR with desc UPnP Media Renderer 1.0
18-Dec-2019 09:20:02.011 [DEBUG] [v.internal.discovery.PhilipsTvDiscoveryParticipant] - Device found: Philips TV DMR with desc UPnP Media Renderer 1.0
18-Dec-2019 09:20:02.012 [DEBUG] [v.internal.discovery.PhilipsTvDiscoveryParticipant] - Discovered a Philips TV '55OLED803/12' model 'Philips TV DMR' thing with UDN 'F00DBABE_AA5E_BABA_DADA_C0D2F3D818B6'
18-Dec-2019 09:20:02.013 [DEBUG] [v.internal.discovery.PhilipsTvDiscoveryParticipant] - Philips TV Found: 192.168.1.60, using default port 1926
18-Dec-2019 09:20:02.024 [DEBUG] [inding.philipstv.internal.handler.PhilipsTvHandler] - thingDiscovered: DiscoveryResult [thingUID=philipstv:tv:F00DBABE_AA5E_BABA_DADA_C0D2F3D818B6, properties={host=192.168.1.60, port=1926}, representationProperty=null, flag=NEW, label=55OLED803/12, bridgeUID=null, ttl=-1, timestamp=1576657202013]
18-Dec-2019 09:20:02.025 [DEBUG] [inding.philipstv.internal.handler.PhilipsTvHandler] - thingDiscovered, thingUID=philipstv:tv:F00DBABE_AA5E_BABA_DADA_C0D2F3D818B6, discoveredUID=philipstv:tv:F00DBABE_AA5E_BABA_DADA_C0D2F3D818B6
18-Dec-2019 09:20:02.028 [INFO ] [inding.philipstv.internal.handler.PhilipsTvHandler] - Starting Refresh Scheduler for Philips TV 55OLED803/12 with refresh rate of 10.
18-Dec-2019 09:20:12.030 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - Target Uri is: https://192.168.1.60:1926/6/audio/volume
18-Dec-2019 09:20:12.672 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - ----------------------------------------
18-Dec-2019 09:20:12.675 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - HTTP/1.1 200 OK
18-Dec-2019 09:20:12.676 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - {"muted":false,"current":10,"min":0,"max":60}
18-Dec-2019 09:20:12.687 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - Target Uri is: https://192.168.1.60:1926/6/applications
18-Dec-2019 09:20:13.461 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - ----------------------------------------
18-Dec-2019 09:20:13.463 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - HTTP/1.1 200 OK
18-Dec-2019 09:20:13.464 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - {"version":2,"applications":[{"label":"Zo kunt u…","intent":{"component":{"packageName":"org.droidtv.eum","className":"org.droidtv.eum.onehelp.HowToTutorials.HowToVideosActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.eum.onehelp.HowToTutorials.HowToVideosActivity-org.droidtv.eum","type":"app"},{"label":"Play Store","intent":{"component":{"packageName":"com.android.vending","className":"com.google.android.finsky.tvmainactivity.TvMainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.google.android.finsky.tvmainactivity.TvMainActivity-com.android.vending","type":"app"},{"label":"YouTube","intent":{"component":{"packageName":"com.google.android.youtube.tv","className":"com.google.android.apps.youtube.tv.activity.ShellActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.google.android.apps.youtube.tv.activity.ShellActivity-com.google.android.youtube.tv","type":"app"},{"label":"TED","intent":{"component":{"packageName":"com.ted.android.tv","className":"com.ted.android.tv.view.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.ted.android.tv.view.MainActivity-com.ted.android.tv","type":"app"},{"label":"Twitch","intent":{"component":{"packageName":"tv.twitch.android.app","className":"tv.twitch.android.apps.TwitchActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"tv.twitch.android.apps.TwitchActivity-tv.twitch.android.app","type":"app"},{"label":"Prime Video","intent":{"component":{"packageName":"com.amazon.amazonvideo.livingroom","className":"com.amazon.ignition.IgnitionActivity"},"action":"empty"},"order":0,"id":"com.amazon.ignition.IgnitionActivity-com.amazon.amazonvideo.livingroom","type":"app"},{"label":"Play Muziek","intent":{"component":{"packageName":"com.google.android.music","className":"com.google.android.music.tv.HomeActivity"},"action":"empty"},"order":0,"id":"com.google.android.music.tv.HomeActivity-com.google.android.music","type":"app"},{"label":"Play Games","intent":{"component":{"packageName":"com.google.android.play.games","className":"com.google.android.apps.play.games.app.atv.features.home.HomeActivity"},"action":"empty"},"order":0,"id":"com.google.android.apps.play.games.app.atv.features.home.HomeActivity-com.google.android.play.games","type":"app"},{"label":"Play Films","intent":{"component":{"packageName":"com.google.android.videos","className":"com.google.android.videos.tv.presenter.activity.TvLauncherActivity"},"action":"empty"},"order":0,"id":"com.google.android.videos.tv.presenter.activity.TvLauncherActivity-com.google.android.videos","type":"app"},{"label":"Netflix","intent":{"component":{"packageName":"com.netflix.ninja","className":"com.netflix.ninja.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.netflix.ninja.MainActivity-com.netflix.ninja","type":"app"},{"label":"Internet Browser","intent":{"component":{"packageName":"com.opera.sdk.example","className":"com.opera.sdk.example.OperaBrowserUiActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.opera.sdk.example.OperaBrowserUiActivity-com.opera.sdk.example","type":"app"},{"label":"Amazon Alexa","intent":{"component":{"packageName":"org.droidtv.amazonalexa","className":"org.droidtv.amazonalexa.wizard.AlexaWizardActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.amazonalexa.wizard.AlexaWizardActivity-org.droidtv.amazonalexa","type":"app"},{"label":"TV-gids","intent":{"component":{"packageName":"org.droidtv.channels","className":"org.droidtv.channels.ChannelsActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.channels.ChannelsActivity-org.droidtv.channels","type":"app"},{"label":"Media","intent":{"component":{"packageName":"org.droidtv.contentexplorer","className":"org.droidtv.contentexplorer.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.contentexplorer.MainActivity-org.droidtv.contentexplorer","type":"app"},{"label":"Demomenu","intent":{"component":{"packageName":"org.droidtv.demome","className":"org.droidtv.demome.DemoMeOptionsActivity"},"action":"empty"},"order":0,"id":"org.droidtv.demome.DemoMeOptionsActivity-org.droidtv.demome","type":"app"},{"label":"Philips TV-collectie","intent":{"component":{"packageName":"org.droidtv.nettv.market","className":"org.droidtv.nettv.market.MarketMainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.nettv.market.MarketMainActivity-org.droidtv.nettv.market","type":"app"},{"label":"Topselectie","intent":{"component":{"packageName":"org.droidtv.nettvrecommender","className":"org.droidtv.nettvrecommender.NetTvRecommenderMainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.nettvrecommender.NetTvRecommenderMainActivity-org.droidtv.nettvrecommender","type":"app"},{"label":"TV","intent":{"component":{"packageName":"org.droidtv.playtv","className":"org.droidtv.playtv.PlayTvActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.playtv.PlayTvActivity-org.droidtv.playtv","type":"app"},{"label":"Disney+","intent":{"component":{"packageName":"com.disney.disneyplus","className":"com.bamtechmedia.dominguez.main.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.bamtechmedia.dominguez.main.MainActivity-com.disney.disneyplus","type":"app"},{"label":"Asphalt Nitro","intent":{"component":{"packageName":"com.gameloft.android.HEP.GloftANHP","className":"com.gameloft.android.HEP.GloftANHP.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.gameloft.android.HEP.GloftANHP.MainActivity-com.gameloft.android.HEP.GloftANHP","type":"game"},{"label":"Spotify","intent":{"component":{"packageName":"com.spotify.tv.android","className":"com.spotify.tv.android.SpotifyTVActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.spotify.tv.android.SpotifyTVActivity-com.spotify.tv.android","type":"app"},{"label":"Tellybean","intent":{"component":{"packageName":"com.tellybean.kahuna.client","className":"com.tellybean.kahuna.client.main.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.tellybean.kahuna.client.main.MainActivity-com.tellybean.kahuna.client","type":"app"},{"label":"NOS","intent":{"component":{"packageName":"nl.nos.app","className":"nl.nos.app.ui.activities.OverviewActivity"},"action":"empty"},"order":0,"id":"nl.nos.app.ui.activities.OverviewActivity-nl.nos.app","type":"app"},{"label":"ARTE","intent":{"component":{"packageName":"org.droidtv.nettvapp1814","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp1814","type":"app"},{"label":"Dailymotion","intent":{"component":{"packageName":"org.droidtv.nettvapp1984","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp1984","type":"app"},{"label":"RTL XL","intent":{"component":{"packageName":"org.droidtv.nettvapp2512","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp2512","type":"app"},{"label":"NPO","intent":{"component":{"packageName":"org.droidtv.nettvapp2786","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp2786","type":"app"},{"label":"Cinetrailer","intent":{"component":{"packageName":"org.droidtv.nettvapp3075","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp3075","type":"app"},{"label":"TV5Monde","intent":{"component":{"packageName":"org.droidtv.nettvapp3814","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp3814","type":"app"},{"label":"Rakuten TV","intent":{"component":{"packageName":"org.droidtv.nettvapp3983","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp3983","type":"app"},{"label":"Pathé Thuis","intent":{"component":{"packageName":"org.droidtv.nettvapp4106","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4106","type":"app"},{"label":"FOX Sports NL","intent":{"component":{"packageName":"org.droidtv.nettvapp4543","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4543","type":"app"},{"label":"MEGOGO","intent":{"component":{"packageName":"org.droidtv.nettvapp4546","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4546","type":"app"},{"label":"Deezer","intent":{"component":{"packageName":"org.droidtv.nettvapp4655","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4655","type":"app"},{"label":"France24","intent":{"component":{"packageName":"org.droidtv.nettvapp4768","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4768","type":"app"},{"label":"Divan.TV","intent":{"component":{"packageName":"org.droidtv.nettvapp4771","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4771","type":"app"},{"label":"Social TV","intent":{"component":{"packageName":"org.droidtv.nettvapp4836","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4836","type":"app"},{"label":"GameTreeTV GOLD","intent":{"component":{"packageName":"org.droidtv.nettvapp4932","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4932","type":"game"},{"label":"Videoland","intent":{"component":{"packageName":"org.droidtv.nettvapp4970","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp4970","type":"app"},{"label":"Filmbox Live","intent":{"component":{"packageName":"org.droidtv.nettvapp5225","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp5225","type":"app"},{"label":"MovieMAX Online","intent":{"component":{"packageName":"org.droidtv.nettvapp5265","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp5265","type":"app"},{"label":"Toon Goggles","intent":{"component":{"packageName":"org.droidtv.nettvapp5326","className":"com.zeasn.app.linux.MainActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"com.zeasn.app.linux.MainActivity-org.droidtv.nettvapp5326","type":"app"},{"label":"Instellingen","intent":{"component":{"packageName":"org.droidtv.settings","className":"org.droidtv.settings.setupmenu.SetupMenuActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.settings.setupmenu.SetupMenuActivity-org.droidtv.settings","type":"app"},{"label":"Zenders instellen","intent":{"component":{"packageName":"org.droidtv.settings","className":"org.droidtv.settings.setupmenu.ChannelSettingActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.settings.setupmenu.ChannelSettingActivity-org.droidtv.settings","type":"app"},{"label":"Zo kunt u…","intent":{"component":{"packageName":"org.droidtv.eum","className":"org.droidtv.eum.onehelp.menu.HowToLauncherActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.eum.onehelp.menu.HowToLauncherActivity-org.droidtv.eum","type":"app"},{"label":"Draadloos en netwerken","intent":{"component":{"packageName":"org.droidtv.settings","className":"org.droidtv.settings.setupmenu.WirelessAndNetworkSettingsActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.settings.setupmenu.WirelessAndNetworkSettingsActivity-org.droidtv.settings","type":"app"},{"label":"Apps beheren","intent":{"component":{"packageName":"com.android.tv.settings","className":"com.android.tv.settings.device.apps.AppsActivity"},"action":"empty"},"order":0,"id":"com.android.tv.settings.device.apps.AppsActivity-com.android.tv.settings","type":"app"},{"label":"Help","intent":{"component":{"packageName":"org.droidtv.eum","className":"org.droidtv.eum.onehelp.menu.OneHelpActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.eum.onehelp.menu.OneHelpActivity-org.droidtv.eum","type":"app"},{"label":"Software bijwerken","intent":{"component":{"packageName":"org.droidtv.settings","className":"org.droidtv.settings.setupmenu.UpdateSWSettingsActivity"},"action":"android.intent.action.MAIN"},"order":0,"id":"org.droidtv.settings.setupmenu.UpdateSWSettingsActivity-org.droidtv.settings","type":"app"}]}
18-Dec-2019 09:20:13.488 [DEBUG] [nhab.binding.philipstv.internal.service.AppService] - Apps added: 48
18-Dec-2019 09:20:13.490 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - Target Uri is: https://192.168.1.60:1926/6/activities/current
18-Dec-2019 09:20:13.610 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - ----------------------------------------
18-Dec-2019 09:20:13.611 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - HTTP/1.1 200 OK
18-Dec-2019 09:20:13.613 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - {"component":{"packageName":"com.netflix.ninja","className":"com.netflix.ninja.MainActivity"}}
18-Dec-2019 09:20:13.618 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - Target Uri is: https://192.168.1.60:1926/6/applications/com.netflix.ninja.MainActivity-com.netflix.ninja/icon
18-Dec-2019 09:20:13.848 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - Target Uri is: https://192.168.1.60:1926/6/channeldb/tv/channelLists/all
18-Dec-2019 09:20:13.954 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - ----------------------------------------
18-Dec-2019 09:20:13.955 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - HTTP/1.1 200 OK
18-Dec-2019 09:20:13.956 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - {"version":0,"id":"all","listType":"MixedSources","medium":"mixed","operator":"None","installCountry":"Netherlands","Channel":[]}
18-Dec-2019 09:20:13.958 [DEBUG] [inding.philipstv.internal.service.TvChannelService] - TV Channels added: 0
18-Dec-2019 09:20:13.959 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - Target Uri is: https://192.168.1.60:1926/6/activities/tv
18-Dec-2019 09:20:14.242 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - ----------------------------------------
18-Dec-2019 09:20:14.243 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - HTTP/1.1 200 OK
18-Dec-2019 09:20:14.243 [DEBUG] [enhab.binding.philipstv.internal.ConnectionManager] - {}

looks like its working fine now.

1 Like

@redviper2100 bad news here: I’ve search around on the web and it seems that other people also expierience exactly the same problem like you guys do. They also reported that their choosen philips tv tool (for homey/iotbroker etc.) doesn’t work with their new 2019er TV model and the tool fails with ERROR 500. I fear until someone takes some time into his hands and technically analyses this TV model, there’s not much I can do. It is quite weird that even the Philips TV Remote App doesn’t want to work…

@Mickroz glad to hear you’ve managed to have another look and that everythings seems to be OK now :wink: enjoy the binding and feel free to ping me again if something pops up.

@Jaykoe Hi Jens, glad to hear the work is appreciated! I’ve also upgraded to OH 2.5 and encountered an error during the first startup, but after removing and adding the binding again everything worked fine. But I did not have a log entry like yours - could you anyway try to remove and add the binding again? Not sure why this line should be a problem:
<description>Ambilight lounge power. Turns ambilight lounge on or off.</description>
Furthermore, the file was actually not changed in the last release…

New Release from today, 18th December:

  • Added Wake-On-LAN Support (retrieves automatically the MAC and uses it if power channel is turned ON)
  • Improved “Standby” logic (= recognize TV is off but network card is on/accepting commands)
  • Diverse refactoring for better error handling

Since a new configuration was added (MAC for WOL), the thing needs to be recreated to be able to see this new configuration at the thing.

@Jaykoe you could try out this version, I’ve separated the xml files. Therefore your problem could be gone with this version.

Thank you. I removed thing and binding and installed everything again. No errors. :+1:
Looking forward to check the new standby logic. :slight_smile:

I’ve been testing the new binding with two Philips TV models:

  • 40PUK6400 (api_version: 6.1.1)
  • 43PUS7202 (api_version: 6.2.0)

Both of them have the latest firmware and a stable connection to the LAN. I have different levels of success. Normally, just after adding the thing and pairing, the TV responds as excpected. However, after switch the TV off and on (with the normal remote), the TV is reported as on, but it does not respond to commands anymore (e.g. mute or switching the channel. In the log I get read timeouts such as:

Error occurred during handling of command for TV Channels: Read timed out
java.net.SocketTimeoutException: Read timed out
        at java.net.SocketInputStream.socketRead0(Native Method) ~[?:1.8.0_232]
        at java.net.SocketInputStream.socketRead(SocketInputStream.java:116) ~[?:1.8.0_232]
        at java.net.SocketInputStream.read(SocketInputStream.java:171) ~[?:1.8.0_232]
        at java.net.SocketInputStream.read(SocketInputStream.java:141) ~[?:1.8.0_232]
        at sun.security.ssl.InputRecord.readFully(InputRecord.java:465) ~[?:1.8.0_232]
        at sun.security.ssl.InputRecord.read(InputRecord.java:503) ~[?:1.8.0_232]
        at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:975) ~[?:1.8.0_232]
        at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:933) ~[?:1.8.0_232]
        at sun.security.ssl.AppInputStream.read(AppInputStream.java:105) ~[?:1.8.0_232]
        at org.apache.http.impl.io.SessionInputBufferImpl.streamRead(SessionInputBufferImpl.java:137) ~[?:?]
        at org.apache.http.impl.io.SessionInputBufferImpl.fillBuffer(SessionInputBufferImpl.java:153) ~[?:?]
        at org.apache.http.impl.io.SessionInputBufferImpl.readLine(SessionInputBufferImpl.java:282) ~[?:?]
        at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:140) ~[?:?]
        at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:57) ~[?:?]
        at org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:259) ~[?:?]
        at org.apache.http.impl.DefaultBHttpClientConnection.receiveResponseHeader(DefaultBHttpClientConnection.java:163) ~[?:?]
        at org.apache.http.impl.conn.CPoolProxy.receiveResponseHeader(CPoolProxy.java:167) ~[?:?]
        at org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:273) ~[?:?]
        at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:125) ~[?:?]
        at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:271) ~[?:?]
        at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:184) ~[?:?]
        at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88) ~[?:?]
        at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110) ~[?:?]
        at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184) ~[?:?]
        at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:117) ~[?:?]
        at org.openhab.binding.philipstv.internal.ConnectionManager.doHttpsGet(ConnectionManager.java:65) ~[?:?]
        at org.openhab.binding.philipstv.internal.service.TvChannelService.getAvailableTvChannelListFromTv(TvChannelService.java:109) ~[?:?]
        at org.openhab.binding.philipstv.internal.service.TvChannelService.handleCommand(TvChannelService.java:70) ~[?:?]
        at org.openhab.binding.philipstv.internal.handler.PhilipsTvHandler.refreshTvProperties(PhilipsTvHandler.java:382) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_232]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:1.8.0_232]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_232]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:1.8.0_232]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_232]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_232]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_232]
19:17:11.742 [INFO ] [smarthome.event.ItemStateChangedEvent] - StopcontactPlaystationPower changed from 29.18 W to 29.14 W
19:17:11.747 [INFO ] [smarthome.event.ItemStateChangedEvent] - StopcontactPlaystationEnergy changed from 7778.75 Wh to 7779.233 Wh
19:17:11.750 [INFO ] [smarthome.event.RuleStatusInfoEvent  ] - 35a195a0-c8de-4817-abc3-b914ff569b97 updated: RUNNING
19:17:11.768 [INFO ] [smarthome.event.RuleStatusInfoEvent  ] - 35a195a0-c8de-4817-abc3-b914ff569b97 updated: IDLE
19:17:11.770 [INFO ] [smarthome.event.ItemStateChangedEvent] - StopcontactPlaystationEnergy_Day changed from 549.583 Wh to 550.066 Wh
19:17:17.136 [INFO ] [smarthome.event.ItemStateChangedEvent] - Playstation_LastSeen changed from 2019-12-21T19:16:52.000+0100 to 2019-12-21T19:17:11.000+0100
19:17:21.681 [WARN ] [lipstv.internal.service.VolumeService] - Error during handling the VolumeService command REFRESH for Channel volume: Read timed out
java.net.SocketTimeoutException: Read timed out
        at java.net.SocketInputStream.socketRead0(Native Method) ~[?:1.8.0_232]
        at java.net.SocketInputStream.socketRead(SocketInputStream.java:116) ~[?:1.8.0_232]
        at java.net.SocketInputStream.read(SocketInputStream.java:171) ~[?:1.8.0_232]
        at java.net.SocketInputStream.read(SocketInputStream.java:141) ~[?:1.8.0_232]
        at sun.security.ssl.InputRecord.readFully(InputRecord.java:465) ~[?:1.8.0_232]
        at sun.security.ssl.InputRecord.read(InputRecord.java:503) ~[?:1.8.0_232]
        at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:975) ~[?:1.8.0_232]
        at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:933) ~[?:1.8.0_232]
        at sun.security.ssl.AppInputStream.read(AppInputStream.java:105) ~[?:1.8.0_232]
        at org.apache.http.impl.io.SessionInputBufferImpl.streamRead(SessionInputBufferImpl.java:137) ~[?:?]
        at org.apache.http.impl.io.SessionInputBufferImpl.fillBuffer(SessionInputBufferImpl.java:153) ~[?:?]
        at org.apache.http.impl.io.SessionInputBufferImpl.readLine(SessionInputBufferImpl.java:282) ~[?:?]
        at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:140) ~[?:?]
        at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:57) ~[?:?]
        at org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:259) ~[?:?]
        at org.apache.http.impl.DefaultBHttpClientConnection.receiveResponseHeader(DefaultBHttpClientConnection.java:163) ~[?:?]
        at org.apache.http.impl.conn.CPoolProxy.receiveResponseHeader(CPoolProxy.java:167) ~[?:?]
        at org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:273) ~[?:?]
        at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:125) ~[?:?]
        at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:271) ~[?:?]
        at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:184) ~[?:?]
        at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88) ~[?:?]
        at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110) ~[?:?]
        at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184) ~[?:?]
        at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:117) ~[?:?]
        at org.openhab.binding.philipstv.internal.ConnectionManager.doHttpsGet(ConnectionManager.java:65) ~[?:?]
        at org.openhab.binding.philipstv.internal.service.VolumeService.getVolume(VolumeService.java:88) ~[?:?]
        at org.openhab.binding.philipstv.internal.service.VolumeService.handleCommand(VolumeService.java:63) ~[?:?]
        at org.openhab.binding.philipstv.internal.handler.PhilipsTvHandler.refreshTvProperties(PhilipsTvHandler.java:374) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_232]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:1.8.0_232]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_232]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:1.8.0_232]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_232]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_232]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_232]

I’ve tried to restart the bundle and restart openhab but this does resolve the issue. Removing and adding the thing works sometimes and sometimes not. So overall a nonstable experience.

Any suggestions what to try next?

(FWIW: I’m running on openhab 2.5.0 in a docker container and had to use feature:install openhab-transport-upnp to get the binding running)

I have tested the new standby logic and it works better but not perfect yet. I have about 20 minutes once a day when the device is reported as turned on although it is not on. Before the update I had more false positives. Therefore it is already an improvement.

Exactly in that time the device appears as a new discovered thing in my inbox - each time with a new device id like philipstv:tv:AAAAAAAA_BBBB_CCCC_DDDD_EEEEEEEEEEEEEEEEEE with the last segment always changing.

@Jaykoe thanks for the feedback! The network card of philips tv’s are normally not really long awake. Most of the times they go into deep sleep after some seconds and then the TV thing will turn to the state OFFLINE. What I’ve missed is to point out that with UPNP Discovery the network card will only be monitored starting at the time of point the TV is turned on until the TV is turned off and the network card goes into deep sleep. Only with constant HTTPS polling the network card state will be checked constantly the whole day.

Let me summarize the logic for standby:

  • Thing state OFFLINE: TV is off and network card is in deep sleep mode and therefore not reachable
  • Thing state ONLINE with Message “Standby”: TV is off and network card is awake and is able to receive commands
  • Thing state ONLINE with any other message than “Standby”: TV is on and network card is awake

Difference of UPNP Discovery and HTTPS constant polling regarding Standby recognition:

  • If TV is turned ON, the TV broadcasts UPNP devices and is therefore recognized as ONLINE at this point of time. If the TV turns off, the network card is watched until it turns off.
  • HTTPS constant polling monitors the network card the whole day through sending commands and therefore monitors the network card nonstop

I’ll add this to the initial post, as this indeed is a source for misunderstandings.

Regarding your observation with the inbox: I’m aware that some TVs are discovered twice, that’s something on my todo list. But the device id’s should always be the same?

Hey @ArdKuijpers are you running the latest version of the binding? Read timeouts are indeed are common problem I’ve encountered with the philips tv’s, sometimes they tend to just not respond. Meanwhile with the latest version of the binding I am not encountering them anymore. How often are you polling, have you adjusted the polling value?

But the device id’s should always be the same?

It is strange: As long as I leave a discovered device in the Inbox, no new one is added. If I add the discovered device as a thing, after some time a new device appears in the inbox with a new last 12 digits in the id.

Hello,

What i did to solve the UPNP problem.
because everytime you clean cashe you have to use the command:

feature:install openhab-transport-upnp

Just install the sonos binding.
And upnp is always working.

I had problems with with th tv if i use the autodiscovery.
so i add it manualy with the IP from the tv.
Everything works great!

PHILIPS 55PUS7272/12

Just upgraded to 2.5 and I get this in startup

[core.thing.internal.ThingManagerImpl] - Exception occurred while calling thing handler factory 'org.openhab.binding.philipstv.internal.handler.PhilipsTvHandlerFactory@3c4226': null

java.lang.NullPointerException: null

	at org.openhab.binding.philipstv.internal.handler.PhilipsTvHandler.<init>(PhilipsTvHandler.java:127) ~[?:?]

	at org.openhab.binding.philipstv.internal.handler.PhilipsTvHandlerFactory.createHandler(PhilipsTvHandlerFactory.java:55) ~[?:?]

Ah, that’s because you might use the latest version but did not recreate the thing. It seems the new configuration for “Use UPnP Discovery” is not set for your thing. After recreation of the thing the value will have the default value “true”. You can avoid redoing the pairing process if you just copy and paste your credentials.

I forgot to add this note to the initial post, thanks for the info.

Yes, I’m running the latest binding as far as I know:

openhab> bundle:list | grep Philips
204 │ Active │  80 │ 2.5.0.201912181751      │ openHAB Add-ons :: Bundles :: Philips TV Binding

I use UPnP and Polling is set to 10s (the default). I will try experimenting with HTTPS polling when I get back home after Christmas. Should I set the polling interval to a larger value to attempt the prevent the timeouts?

Really weird, I’m owning a 7101 model with UPnP enabled and polling set to 2s and everything works fine. So raising the polling value shouldn’t change anything, also switching over to constant HTTPS polling. Sometimes my tv responded with such exceptions, if too many requests were fired and connections were not reused. But this has been addressed by the binding since quite a while.

Would you mind setting the logging level to DEBUG and have a look at the logs? It will output every request and whatever is going on. Might give us some insights what’s going on exactly.

Hi @Maarten_Mees @redviper2100,

it came to my attention that some days ago another TV software update for 2019er models was released. This update may be an answer to the bad reviews in the google play store for the Philips TV Remote App as it doesn’t work for 2019er models. If so, you could be able to use this binding after updating your tvs.

1 Like

Most likely I will update it tomorrow. Hope it works.
Thanks for the info :slight_smile:

New Release 28.12.19:

  • Minor changes to retry logic: Don’t retry requests if tv is off or does not accept commands

  • Added Wake-On-LAN functionality also to Ambilight Lounge: If ambilight lounge power is turned on and the tv is off (= network card is in deep sleep), it’s turned on via Wake-On-LAN and ambilight lounge will be toggled

I have the same problem, but my Philips thing config is in files (I think it’s more stable for me. When I had all defined in PaperUI I had some connection errors). Is there some parameter I could add to thing config files that will define “Use UPnP Discovery” to “true”?

That’s weird, because the setting for “Use UPnP Discovery” should be by default “true”. I’ll have another look into this. What kind of connection errors did you experience with a thing in paper ui?

But please note that UPnP in combination with a thing file works best, if you use the same thingUID in the name as in the created thing in the paper ui inbox.

The property name you are looking for is “useUpnpDiscovery”.

Hi,
I’m using the latest version 2.5.0.201912281131
keep on getting
Error occurred during handling of command for TV Channels: Read timed out
Is there already a fix for that? Or if that is going to be business as usual… can we make this less verbose