Sony Devices Binding

maybe we should discuss this in a private chat. I need to get an understanding what that means. Lets say: I’m not very happy on the current status 2.4 vs. 2.5 build system from a developer’s/my personal point of view. We need a clear concept here rather them “let the developers find it out themself”

Would it be possible to restrict the discovery on non-blue ray devices. The binding detects properly my TV and the DIAL thing is useless and needs to be hidden

I could provide DEBUG or TRACE log, no problem.
For me it looks:

  • when the binding finds the value in the transform nothing happens
  • otherwise an error is displayed

all good, was just confusing to me compared to the old one. created a one-time hazel, because I need to replace all switch items with buttons on by HABpanel

the TRACE output when using the IRCC channel

2019-06-11 16:17:47.955 [nt.ItemStatePredictedEvent] - TVWohnzimmer_IRCC predicted to become Home

==> /usr/share/openhab2/log/openhab.log <==
2019-06-11 16:17:48.146 [DEBUG] [inding.sony.internal.net.HttpRequest] - 1 * Sending client request on thread safeCall-576
1 > GET http://192.168.6.22:49800/sony/webapi/ssdp/dd.xml
1 > Connection: close
1 > User-Agent: OpenHab/Sony/Binding
1 > X-CERS-DEVICE-ID: MediaRemote:00-11-22-33-44-55
1 > X-CERS-DEVICE-INFO: OpenHab/Sony/Binding

2019-06-11 16:17:48.177 [DEBUG] [inding.sony.internal.net.HttpRequest] - 1 * Client response received on thread safeCall-576
1 < 200
1 < Accept-Range: none
1 < Connection: close
1 < Content-Length: 5528
1 < Content-Type: text/xml; charset="utf-8"
1 < Date: Tue, 11 Jun 2019 14:17:50 GMT
1 < Server: FedoraCore/2 UPnP/1.0 MINT-X/1.8.1
<?xml version="1.0"?>
<root xmlns="urn:schemas-upnp-org:device-1-0">
  <specVersion>
    <major>1</major>
    <minor>0</minor>
  </specVersion>
  <device>
    <deviceType>urn:schemas-upnp-org:device:Basic:1</deviceType>
    <friendlyName>TV Wohnzimmer</friendlyName>
    <manufacturer>Sony Corporation</manufacturer>
    <manufacturerURL>http://www.sony.net/</manufacturerURL>
    <modelName>KD-65XF8505</modelName>
    <UDN>uuid:63c471f2-782b-496e-81ce-7fb57bd3dec0</UDN>
    
<iconList>
      <icon>
        <mimetype>image/jpeg</mimetype>
        <width>120</width>
        <height>120</height>
        <depth>24</depth>
        <url>/sony/webapi/ssdp/icon/dlna_tv_120.jpg</url>
      </icon>
      <icon>
        <mimetype>image/png</mimetype>
        <width>120</width>
        <height>120</height>
        <depth>24</depth>
        <url>/sony/webapi/ssdp/icon/dlna_tv_120.png</url>
      </icon>
      <icon>
        <mimetype>image/jpeg</mimetype>
        <width>32</width>
        <height>32</height>
        <depth>24</depth>
        <url>/sony/webapi/ssdp/icon/dlna_tv_32.jpg</url>
      </icon>
      <icon>
        <mimetype>image/png</mimetype>
        <width>32</width>
        <height>32</height>
        <depth>24</depth>
        <url>/sony/webapi/ssdp/icon/dlna_tv_32.png</url>
      </icon>
      <icon>
        <mimetype>image/jpeg</mimetype>
        <width>48</width>
        <height>48</height>
        <depth>24</depth>
        <url>/sony/webapi/ssdp/icon/dlna_tv_48.jpg</url>
      </icon>
      <icon>
        <mimetype>image/png</mimetype>
        <width>48</width>
        <height>48</height>
        <depth>24</depth>
        <url>/sony/webapi/ssdp/icon/dlna_tv_48.png</url>
      </icon>
      <icon>
        <mimetype>image/jpeg</mimetype>
        <width>60</width>
        <height>60</height>
        <depth>24</depth>
        <url>/sony/webapi/ssdp/icon/dlna_tv_60.jpg</url>
      </icon>
      <icon>
        <mimetype>image/png</mimetype>
        <width>60</width>
        <height>60</height>
        <depth>24</depth>
        <url>/sony/webapi/ssdp/icon/dlna_tv_60.png</url>
      </icon>
</iconList>
    <serviceList>

      <service>
        <serviceType>urn:schemas-sony-com:service:ScalarWebAPI:1</serviceType>
        <serviceId>urn:schemas-sony-com:serviceId:ScalarWebAPI</serviceId>
        <SCPDURL>/sony/webapi/ssdp/scpd/WebApiSCPD.xml</SCPDURL>
        <controlURL>http://192.168.6.22/sony</controlURL>
        <eventSubURL></eventSubURL>
      </service>
      <service>
        <serviceType>urn:schemas-sony-com:service:IRCC:1</serviceType>
        <serviceId>urn:schemas-sony-com:serviceId:IRCC</serviceId>
        <SCPDURL>http://192.168.6.22/sony/ircc/IRCCSCPD.xml</SCPDURL>
        <controlURL>http://192.168.6.22/sony/ircc</controlURL>
        <eventSubURL/>
      </service>
    </serviceList>


    <av:X_ScalarWebAPI_DeviceInfo xmlns:av="urn:schemas-sony-com:av">
      <av:X_ScalarWebAPI_Version>1.0</av:X_ScalarWebAPI_Version>
      <av:X_ScalarWebAPI_BaseURL>http://192.168.6.22/sony</av:X_ScalarWebAPI_BaseURL>
      <av:X_ScalarWebAPI_ServiceList>











        <av:X_ScalarWebAPI_ServiceType>guide</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>recording</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>browser</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>accessControl</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>encryption</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>contentshare</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>avContent</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>cec</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>audio</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>appControl</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>system</av:X_ScalarWebAPI_ServiceType>        <av:X_ScalarWebAPI_ServiceType>videoScreen</av:X_ScalarWebAPI_ServiceType>
      </av:X_ScalarWebAPI_ServiceList>
    </av:X_ScalarWebAPI_DeviceInfo>
    <av:X_IRCC_DeviceInfo xmlns:av="urn:schemas-sony-com:av">
      <av:X_IRCC_Version>1.0</av:X_IRCC_Version>
      <av:X_IRCC_CategoryList>
        <av:X_IRCC_Category>
          <av:X_CategoryInfo>AAEAAAAB</av:X_CategoryInfo>
        </av:X_IRCC_Category>
        <av:X_IRCC_Category>
          <av:X_CategoryInfo>AAIAAACk</av:X_CategoryInfo>
        </av:X_IRCC_Category>
        <av:X_IRCC_Category>
          <av:X_CategoryInfo>AAIAAACX</av:X_CategoryInfo>
        </av:X_IRCC_Category>
        <av:X_IRCC_Category>
          <av:X_CategoryInfo>AAIAAAB3</av:X_CategoryInfo>
        </av:X_IRCC_Category>
        <av:X_IRCC_Category>
          <av:X_CategoryInfo>AAIAAAAa</av:X_CategoryInfo>
        </av:X_IRCC_Category>
      </av:X_IRCC_CategoryList>
    </av:X_IRCC_DeviceInfo>
    <av:X_IRCCCodeList xmlns:av="urn:schemas-sony-com:av">
      <av:X_IRCCCode command="Power">AAAAAQAAAAEAAAAVAw==</av:X_IRCCCode>
    </av:X_IRCCCodeList>
    <av:X_RDIS_DeviceInfo xmlns:av="urn:schemas-sony-com:av">
      <av:X_RDIS_Version>1.0</av:X_RDIS_Version>
      <av:X_RDIS_SESSION_CONTROL>true</av:X_RDIS_SESSION_CONTROL>
      <av:X_RDIS_KEEP_ALIVE>false</av:X_RDIS_KEEP_ALIVE>
      <av:X_RDIS_ENTRY_PORT>50857</av:X_RDIS_ENTRY_PORT>
    </av:X_RDIS_DeviceInfo>
  </device>
</root>


2019-06-11 16:17:48.204 [DEBUG] [inding.sony.internal.net.HttpRequest] - 2 * Sending client request on thread safeCall-576
2 > GET http://192.168.6.22:49800/sony/webapi/ssdp/scpd/WebApiSCPD.xml
2 > Connection: close
2 > User-Agent: OpenHab/Sony/Binding
2 > X-CERS-DEVICE-ID: MediaRemote:00-11-22-33-44-55
2 > X-CERS-DEVICE-INFO: OpenHab/Sony/Binding

2019-06-11 16:17:48.217 [DEBUG] [inding.sony.internal.net.HttpRequest] - 2 * Client response received on thread safeCall-576
2 < 200
2 < Accept-Range: none
2 < Connection: close
2 < Content-Length: 323
2 < Content-Type: text/xml; charset="utf-8"
2 < Date: Tue, 11 Jun 2019 14:17:50 GMT
2 < Last-Modified: Tue, 21 May 2019 23:16:20 GMT
2 < Server: FedoraCore/2 UPnP/1.0 MINT-X/1.8.1
<?xml version="1.0"?>
<scpd xmlns="urn:schemas-upnp-org:service-1-0">
  <specVersion>
    <major>1</major>
    <minor>0</minor>
  </specVersion>
  <serviceStateTable>
    <stateVariable sendEvents="no">
      <name>X_ScalarWebAPI</name>
      <dataType>string</dataType>
    </stateVariable>
  </serviceStateTable>
</scpd>


2019-06-11 16:17:48.234 [DEBUG] [inding.sony.internal.net.HttpRequest] - 3 * Sending client request on thread safeCall-576
3 > GET http://192.168.6.22/sony/ircc/IRCCSCPD.xml
3 > Connection: close
3 > User-Agent: OpenHab/Sony/Binding
3 > X-CERS-DEVICE-ID: MediaRemote:00-11-22-33-44-55
3 > X-CERS-DEVICE-INFO: OpenHab/Sony/Binding

2019-06-11 16:17:48.265 [DEBUG] [inding.sony.internal.net.HttpRequest] - 3 * Client response received on thread safeCall-576
3 < 200
3 < Connection: close
3 < Transfer-Encoding: chunked
<?xml version="1.0"?>
<scpd xmlns="urn:schemas-upnp-org:service-1-0">
  <specVersion>
    <major>1</major>
    <minor>0</minor>
  </specVersion>
  <actionList>
    <action>
      <name>X_SendIRCC</name>
      <argumentList>
        <argument>
          <name>IRCCCode</name>
          <direction>in</direction>
          <relatedStateVariable>X_A_ARG_TYPE_IRCCCode</relatedStateVariable>
        </argument>
      </argumentList>
    </action>
    <action>
      <name>X_GetStatus</name>
      <argumentList>
        <argument>
          <name>CategoryCode</name>
          <direction>in</direction>
          <relatedStateVariable>X_A_ARG_TYPE_Category</relatedStateVariable>
        </argument>
        <argument>
          <name>CurrentStatus</name>
          <direction>out</direction>
          <relatedStateVariable>X_A_ARG_TYPE_CurrentStatus</relatedStateVariable>
        </argument>
        <argument>
          <name>CurrentCommandInfo</name>
          <direction>out</direction>
          <relatedStateVariable>X_A_ARG_TYPE_CurrentCommandInfo</relatedStateVariable>
        </argument>
      </argumentList>
    </action>
  </actionList>
  <serviceStateTable>
    <stateVariable sendEvents="no">
      <name>X_A_ARG_TYPE_IRCCCode</name>
      <dataType>string</dataType>
    </stateVariable>
    <stateVariable sendEvents="no">
      <name>X_A_ARG_TYPE_Category</name>
      <dataType>string</dataType>
    </stateVariable>
    <stateVariable sendEvents="no">
      <name>X_A_ARG_TYPE_CurrentStatus</name>
      <dataType>string</dataType>
      <allowedValueList>
        <allowedValue>0</allowedValue>
        <allowedValue>801</allowedValue>
        <allowedValue>804</allowedValue>
        <allowedValue>805</allowedValue>
        <allowedValue>806</allowedValue>
      </allowedValueList>
    </stateVariable>
    <stateVariable sendEvents="no">
      <name>X_A_ARG_TYPE_CurrentCommandInfo</name>
      <dataType>string</dataType>
    </stateVariable>
  </serviceStateTable>
</scpd>


2019-06-11 16:17:48.279 [DEBUG] [sony.internal.ircc.models.IrccClient] - No actionsurl - generating default
2019-06-11 16:17:48.284 [DEBUG] [ernal.ircc.models.IrccRemoteCommands] - Cannot add code list Power to commands as command AAAAAQAAAAEAAAAVAw== already exists for TvPower
2019-06-11 16:17:48.290 [DEBUG] [eb.protocols.ScalarWebSystemProtocol] - Transformed Home with map file 'scalar-7fb57bd3dec0.map' to AAAAAQAAAAEAAABgAw%3D%3D
2019-06-11 16:17:48.293 [DEBUG] [alarweb.transports.SonyIrccTransport] - Sending IRCC command: AAAAAQAAAAEAAABgAw== to http://192.168.6.22/sony/ircc
2019-06-11 16:17:48.320 [DEBUG] [alarweb.transports.SonyIrccTransport] - Execution of IRCC command AAAAAQAAAAEAAABgAw== to http://192.168.6.22/sony/ircc failed with 403
2019-06-11 16:17:48.323 [DEBUG] [alarweb.transports.SonyIrccTransport] - Closing IRCC client to http://192.168.6.22:49800/sony/webapi/ssdp/dd.xml
2019-06-11 16:17:48.329 [DEBUG] [eb.protocols.ScalarWebSystemProtocol] - Scalar methods have been forbidden on service system (http://192.168.6.22:49800/sony/webapi/ssdp/dd.xml): 403 (http reason: )
2019-06-11 16:18:10.757 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 1805, [], [40005,"Display Is Turned off"]
2019-06-11 16:18:10.764 [DEBUG] [.protocols.AbstractScalarWebProtocol] - The display is off and command cannot be executed on service audio - getVolumeInformation(): 40005, Display Is Turned off

I see:
** [DEBUG] [alarweb.transports.SonyIrccTransport] - Execution of IRCC command AAAAAQAAAAEAAABgAw== to http://192.168.6.22/sony/ircc failed with 403**

I sent you a PM, happy to help

1 Like

So the 403 is what is getting you. Two things I need you to try:

  1. Turn on the TV and see if it starts working. If it does, sony might be starting to lock down the IRCC service now. If it doesn’t…
  2. Since your IRCC service came online - try to send the command through it (rather than scalar). Really should be exactly the same - but would be interesting if it worked (URL would be the only real difference). If it does work, I’ll need the log from the IRCC service to see what’s different. If it doesn’t work - then we’ll try something else that I’d like to avoid…

no, doesn’t work, same error code
that’s the output from the IRCC thing:

2019-06-12 17:31:32.340 [DEBUG] [g.sony.internal.AbstractThingHandler] - Checking connectivity to 192.168.6.22:2706 - successful

==> /usr/share/openhab2/log/events.log <==
2019-06-12 17:31:38.236 [ome.event.ItemCommandEvent] - Item 'TVWohnzimmer_IRCC' received command Home
2019-06-12 17:31:38.244 [nt.ItemStatePredictedEvent] - TVWohnzimmer_IRCC predicted to become Home

==> /usr/share/openhab2/log/openhab.log <==
2019-06-12 17:31:38.253 [DEBUG] [ding.sony.internal.ircc.IrccProtocol] - Transformed Home with map file 'ircc-7fb57bd3dec0.map' to ircc:AAAAAQAAAAEAAABgAw%3D%3D
2019-06-12 17:31:38.355 [ERROR] [ding.sony.internal.ircc.IrccProtocol] - Bad return code from X_SendIRCC: 403 (http reason: Forbidden)
2019-06-12 17:31:38.572 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 17, [{"status":"active"}], []
2019-06-12 17:31:38.801 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 26, [[{"scheme":"tv"},{"scheme":"extInput"},{"scheme":"fav"},{"scheme":"usb"}]], []
2019-06-12 17:31:38.809 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 11, [[{"target":"speaker","volume":24,"mute":false,"maxVolume":100,"minVolume":0},{"target":"headphone","volume":15,"mute":false,"maxVolume":100,"minVolume":0}]], []
2019-06-12 17:31:38.887 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 27, [[{"source":"tv:dvbs"}]], []
2019-06-12 17:31:38.992 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 28, [[{"source":"extInput:hdmi"},{"source":"extInput:component"},{"source":"extInput:cec"},{"source":"extInput:widi"}]], []
2019-06-12 17:31:39.039 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 29, [[{"source":"usb:recStorage"}]], []
2019-06-12 17:31:39.095 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 30, [[{"source":"fav:tv?id=1"},{"source":"fav:tv?id=2"},{"source":"fav:tv?id=3"},{"source":"fav:tv?id=4"}]], []
2019-06-12 17:31:39.317 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 31, [], [7,"Illegal State"]
2019-06-12 17:31:39.321 [DEBUG] [.protocols.AbstractScalarWebProtocol] - Method state is incorrect on service avContent - getPlayingContentInfo([Ljava.lang.Object;@16d9ae7): 7, Illegal State
2019-06-12 17:31:39.468 [WARN ] [rm.AbstractFileTransformationService] - Could not transform 'Waxing Gibbous' with the file 'astro.map' : Target value not found in map for 'Waxing Gibbous'
2019-06-12 17:31:40.050 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Amazon - AFTT
2019-06-12 17:31:44.291 [DEBUG] [g.sony.internal.AbstractThingHandler] - Checking connectivity to 192.168.6.22:2706 - successful

some additional information

  • Simple IP is disabled
  • Authentication is set to Normal+Preshared Key
  • a preshared key is configured
  • access code in the thing config is set to “RQST”
  • TV shows an "Android 8.0 Oreo Introduction) - first time I recognized that (might be an indicator for an updated Android, but nur sure)
    Does the binding support pre-shared keys?

It seems that there is a registered openHAB remote (I assume from the old installation), but the TV shows a remote MAC of 00-11-22-33-44-55? Does the TV identifies the remote based on the MAC address? How could I enforce an authentication? I would expect that RQST always show up on the TV and requests a PIN code, but it doesn’t even I changed from the old version to the new one.

nope, I used the old binding the in a similar way, except that I send the IRCC codes directly to the binding (rather than using the transform).

I tried

  • putting the MAC in the thing config
  • standby off/on
  • power off/on
  • deregister and register the openHAB remote
  • changed PIN in thing confug
    without success, still getting 403

In addition I see those messages form time to time

 [DEBUG] [.protocols.AbstractScalarWebProtocol] - Method state is incorrect on service avContent - getPlayingContentInfo([Ljava.lang.Object;@5f99c6): 7, Illegal State

e.g.

2019-06-12 17:50:25.287 [DEBUG] [nal.scalarweb.models.ScalarWebResult] - >>> result: 31, [], [7,"Illegal State"]
2019-06-12 17:50:25.290 [DEBUG] [.protocols.AbstractScalarWebProtocol] - Method state is incorrect on service avContent - getPlayingContentInfo([Ljava.lang.Object;@213ea0): 7, Illegal State
2019-06-12 17:50:25.328 [DEBUG] [g.sony.internal.AbstractThingHandler] - Checking connectivity to 192.168.6.22:12178 - successful
2019-06-12 17:50:25.332 [DEBUG] [ding.sony.internal.ircc.IrccProtocol] - getStatus is not implemented
2019-06-12 17:50:25.337 [DEBUG] [g.sony.internal.AbstractThingHandler] - Checking connectivity to 192.168.6.22:12178 - successful

Anything else I could try?

You’ve pretty much covered the bases. The MAC address of 00-11-… is just hardcoded into the binding - the TV doesn’t care if it’s valid or not and simply uses it as an identifier (and by hardcoding- it shares the same authority across all the services). Changing the mac address in the config only affects sending the WOL on power on.

The only thing I’d try is the preshared key at this point - just replace RQST with your preshared key - restart the binding and see if it starts to work.

I’m going to be gone for the next 5 days - but after that I’ll update my TVs to the latest firmware and see if this is something new from sony…

I deregistered the oh remote, did a new register, put the pin in the thing config = same result

Hi,
In trying the Sony Binding in OpenHab 2.4 and its working fine with my Bravia KD54-A1
The channel use is clear, but the browser ones are a bit confusing:

Browser Activate (String)
Browser URL (String) that’s clear and working
Browser URL Title (String) tried but not working, or nothing happened
Browser URL Type (String)
Browser URL Favicon (String) I suppose the string is a coded image to use as an icon (not tried yet)

Does someone know what kind of string I’m supposed to pass the Activate and Type?
Regards

You’re a bit on your own - none of my devices implement the browser service so I can’t test. However, here is a few comments:

  1. Title - your device may not be giving a title back. You can test this by turning debug on for the addon, navigate to some page on the TV (that shows a title in the titlebar) and then search the log file for that URL. You should find a “getTextUrl” call that returns something like “{ url: whatever, title: xxx …}”. If title is missing or blank - you’re TV simply doesn’t communicate that element. HOWEVER - if it does show a title - then I need to fix something and I’d like you to post the results of that getTextUrl call…
  2. Type - that’s a readonly field so you can’t pass anything to it.
  3. Activate - I’d simply start sending things to it “active”, “on”, “start”, maybe a URL. However, I don’t think you really need that channel - I’m betting if you send a URL to the “Browser URL” channel when you are watching TV, the browser will automatically get activated. Just a pure guess but something to try.

You are right, if I send the url the TV switches to the browser and shows the page.
thx

How do we update this binding, I have just updated openhab using openhab-config. and my binding is not showing the tv as online.

edit.
Scratch that. Had to install the binding using paper UI again for some reason, and it connected without any other issues

@tmrobert8 I still have the same problem

  • re-registered the binding, TV shows an openHAB remote
  • TV and IRCC device come online
  • I set the access code in both TV thing and IRCC thing
  • IRCC command channel doesn’t work, error 403 - fornbidden
    = binding starts, things online, but I can’t control the TV
2019-06-24 22:17:22.697 [INFO ] [nding.sony.internal.ircc.IrccHandler] - Attempting connection to IRCC device...
2019-06-24 22:17:22.537 [ERROR] [org.openhab.binding.sony            ] - bundle org.openhab.binding.sony:2.4.0.201906101920 (170)[org.openhab.binding.sony.discovery.simpleip(227)] : Could not load implementation object class org.openhab.binding.sony.discovery.SimpleIpDiscoveryParticipant
java.lang.ClassNotFoundException: org.openhab.binding.sony.discovery.SimpleIpDiscoveryParticipant cannot be found by org.openhab.binding.sony_2.4.0.201906101920
2019-06-24 22:17:22.708 [ERROR] [org.openhab.binding.sony            ] - bundle org.openhab.binding.sony:2.4.0.201906101920 (170)[org.openhab.binding.sony.discovery.ircc(230)] : Could not load implementation object class org.openhab.binding.sony.discovery.IrccDiscoveryParticipant
java.lang.ClassNotFoundException: org.openhab.binding.sony.discovery.IrccDiscoveryParticipant cannot be found by org.openhab.binding.sony_2.4.0.201906101920
2019-06-24 22:17:22.710 [ERROR] [org.openhab.binding.sony            ] - FrameworkEvent ERROR - org.openhab.binding.sony
Caused by: java.lang.IllegalStateException: Could not load implementation object class org.openhab.binding.sony.discovery.SimpleIpDiscoveryParticipant
2019-06-24 22:17:22.730 [ERROR] [org.openhab.binding.sony            ] - bundle org.openhab.binding.sony:2.4.0.201906101920 (170)[org.openhab.binding.sony.discovery.dial(232)] : Could not load implementation object class org.openhab.binding.sony.discovery.DialDiscoveryParticipant
java.lang.ClassNotFoundException: org.openhab.binding.sony.discovery.DialDiscoveryParticipant cannot be found by org.openhab.binding.sony_2.4.0.201906101920
2019-06-24 22:17:23.846 [ERROR] [org.openhab.binding.sony            ] - FrameworkEvent ERROR - org.openhab.binding.sony
Caused by: java.lang.IllegalStateException: Could not load implementation object class org.openhab.binding.sony.discovery.IrccDiscoveryParticipant
2019-06-24 22:17:23.909 [ERROR] [org.openhab.binding.sony            ] - bundle org.openhab.binding.sony:2.4.0.201906101920 (170)[org.openhab.binding.sony.discovery.scalarweb(236)] : Could not load implementation object class org.openhab.binding.sony.discovery.ScalarWebDiscoveryParticipant
java.lang.ClassNotFoundException: org.openhab.binding.sony.discovery.ScalarWebDiscoveryParticipant cannot be found by org.openhab.binding.sony_2.4.0.201906101920
2019-06-24 22:17:24.561 [ERROR] [org.openhab.binding.sony            ] - FrameworkEvent ERROR - org.openhab.binding.sony
Caused by: java.lang.IllegalStateException: Could not load implementation object class org.openhab.binding.sony.discovery.DialDiscoveryParticipant
2019-06-24 22:17:24.829 [ERROR] [org.openhab.binding.sony            ] - FrameworkEvent ERROR - org.openhab.binding.sony
Caused by: java.lang.IllegalStateException: Could not load implementation object class org.openhab.binding.sony.discovery.ScalarWebDiscoveryParticipant
2019-06-24 22:17:25.114 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Sony - BRAVIA 4K GB ATV3
2019-06-24 22:17:25.125 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Sony Corporation - KD-65XF8505
2019-06-24 22:17:25.147 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Sony Corporation - KD-65XF8505
2019-06-24 22:17:25.158 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Sony Corporation - MediaRenderer
2019-06-24 22:17:27.608 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Sony - BRAVIA 4K GB ATV3
2019-06-24 22:17:27.688 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Sony Corporation - KD-65XF8505
2019-06-24 22:17:27.804 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Sony Corporation - KD-65XF8505
2019-06-24 22:17:27.904 [TRACE] [.magentatv.internal.MagentaTVHandler] - Device discovered: Sony Corporation - MediaRenderer
2019-06-24 22:17:27.992 [INFO ] [nding.sony.internal.ircc.IrccHandler] - Attempting connection to IRCC device...
2019-06-24 22:17:28.011 [INFO ] [g.discovery.internal.PersistentInbox] - Added new thing 'sony:dial:7992d0abbbe6' to inbox.
2019-06-24 22:17:28.020 [me.event.ThingUpdatedEvent] - Thing 'sony:ircc:7fb57bd3dec0' has been updated.
2019-06-24 22:17:28.023 [home.event.InboxAddedEvent] - Discovery Result with UID 'sony:dial:7992d0abbbe6' has been added.
2019-06-24 22:17:28.141 [INFO ] [ding.sony.internal.ircc.IrccProtocol] - Command map already defined - ignoring: /etc/openhab2/transform/ircc-7fb57bd3dec0.map
2019-06-24 22:17:28.151 [hingStatusInfoChangedEvent] - 'sony:ircc:7fb57bd3dec0' changed from OFFLINE (COMMUNICATION_ERROR): Error connecting to IRCC device (may need to turn it on manually): java.net.ConnectException: Connection refused (Connection refused) to ONLINE
2019-06-24 22:17:28.155 [INFO ] [g.sony.internal.AbstractThingHandler] - Starting state polling every 30 seconds
2019-06-24 22:17:28.173 [INFO ] [g.sony.internal.AbstractThingHandler] - Starting state polling every 30 seconds
2019-06-24 22:17:28.534 [me.event.ThingUpdatedEvent] - Thing 'sony:scalar:7fb57bd3dec0' has been updated.
2019-06-24 22:17:31.097 [hingStatusInfoChangedEvent] - 'sony:scalar:7fb57bd3dec0' changed from OFFLINE (COMMUNICATION_ERROR): Unhandled exception connecting to Scalar Web device (may need to turn it on manually): java.net.ConnectException: Connection refused (Connection refused) to OFFLINE (CONFIGURATION_ERROR): Access Code requested. Please update the Access Code with what is shown on the device screen
2019-06-24 22:18:04.085 [vent.ItemStateChangedEvent] - SonyTVWohnzimmer_WOL changed from NULL to ON
2019-06-24 22:18:27.247 [me.event.ThingUpdatedEvent] - Thing 'sony:scalar:7fb57bd3dec0' has been updated.
2019-06-24 22:18:36.312 [INFO ] [g.sony.internal.AbstractThingHandler] - Starting state polling every 30 seconds
2019-06-24 22:18:36.346 [me.event.ThingUpdatedEvent] - Thing 'sony:scalar:7fb57bd3dec0' has been updated.
2019-06-24 22:18:36.364 [hingStatusInfoChangedEvent] - 'sony:scalar:7fb57bd3dec0' changed from OFFLINE (CONFIGURATION_ERROR): Access Code requested. Please update the Access Code with what is shown on the device screen to ONLINE
2019-06-24 22:21:21.330 [me.event.ThingUpdatedEvent] - Thing 'sony:ircc:7fb57bd3dec0' has been updated.
2019-06-24 22:21:21.335 [INFO ] [nding.sony.internal.ircc.IrccHandler] - Attempting connection to IRCC device...
2019-06-24 22:21:21.592 [INFO ] [nding.sony.internal.ircc.IrccHandler] - Attempting connection to IRCC device...
2019-06-24 22:21:21.606 [me.event.ThingUpdatedEvent] - Thing 'sony:ircc:7fb57bd3dec0' has been updated.
2019-06-24 22:21:21.617 [hingStatusInfoChangedEvent] - 'sony:ircc:7fb57bd3dec0' changed from ONLINE to OFFLINE (HANDLER_INITIALIZING_ERROR): Initialization was interrupted
2019-06-24 22:21:31.768 [INFO ] [nding.sony.internal.ircc.IrccHandler] - Attempting connection to IRCC device...
2019-06-24 22:21:31.914 [INFO ] [ding.sony.internal.ircc.IrccProtocol] - Command map already defined - ignoring: /etc/openhab2/transform/ircc-7fb57bd3dec0.map
2019-06-24 22:21:31.921 [INFO ] [g.sony.internal.AbstractThingHandler] - Starting state polling every 30 seconds
2019-06-24 22:21:31.920 [hingStatusInfoChangedEvent] - 'sony:ircc:7fb57bd3dec0' changed from OFFLINE (HANDLER_INITIALIZING_ERROR): Initialization was interrupted to ONLINE
2019-06-24 22:21:31.927 [INFO ] [g.sony.internal.AbstractThingHandler] - Starting state polling every 30 seconds
2019-06-24 22:22:01.329 [ERROR] [ding.sony.internal.ircc.IrccProtocol] - Bad return code from X_SendIRCC: 403 (http reason: Forbidden)

you need to copy the .jar file to the addons folder, make sure you use the latest build (not the one from the marketplace / installable within PaperUI). If you are running OH 2.4 you could use this version:
https://github.com/markus7017/org.openhab.binding.sony.24/blob/master/target/org.openhab.binding.sony-2.4.0-SNAPSHOT.jar

As stated, I re ran the 2.5.0 snapshot
binding install from paper UI and it just worked.

I have not forgotten about this issue but haven’t gotten back around to it - probably later today or tomorrow…

Hey Tim,
Did you get my pm with the log?

I don’t think I did actually

Hi Tim,
I’m testing the binding and after few days it stops working.
To be honest the only function that is working is the Power switch in read-only (status update correctly) but if I switch nothing happens.
If I restart the bundle everything starts working again

Here the log of the errors after the bundle restart:

16:09:53.201 [ERROR] [.protocols.ScalarWebAvContentProtocol] - Exception occurred retrieving the content list for scheme ‘fav’ and source ‘fav:tv?id=1’: Illegal Argument
java.io.IOException: Illegal Argument
at org.openhab.binding.sony.internal.net.HttpResponse.createException(HttpResponse.java:188) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.AbstractScalarWebProtocol.execute(AbstractScalarWebProtocol.java:100) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebAvContentProtocol.getChannelDescriptors(ScalarWebAvContentProtocol.java:360) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebProtocolFactory.getChannelDescriptors(ScalarWebProtocolFactory.java:133) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.initializeTask(ScalarWebHandler.java:191) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.access$1(ScalarWebHandler.java:160) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler$2.run(ScalarWebHandler.java:152) [331:org.openhab.binding.sony:2.2.0.201711091019]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]
16:09:53.325 [ERROR] [.protocols.ScalarWebAvContentProtocol] - Exception occurred retrieving the content list for scheme ‘fav’ and source ‘fav:tv?id=2’: Illegal Argument
java.io.IOException: Illegal Argument
at org.openhab.binding.sony.internal.net.HttpResponse.createException(HttpResponse.java:188) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.AbstractScalarWebProtocol.execute(AbstractScalarWebProtocol.java:100) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebAvContentProtocol.getChannelDescriptors(ScalarWebAvContentProtocol.java:360) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebProtocolFactory.getChannelDescriptors(ScalarWebProtocolFactory.java:133) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.initializeTask(ScalarWebHandler.java:191) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.access$1(ScalarWebHandler.java:160) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler$2.run(ScalarWebHandler.java:152) [331:org.openhab.binding.sony:2.2.0.201711091019]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]
16:09:53.444 [ERROR] [.protocols.ScalarWebAvContentProtocol] - Exception occurred retrieving the content list for scheme ‘fav’ and source ‘fav:tv?id=3’: Illegal Argument
java.io.IOException: Illegal Argument
at org.openhab.binding.sony.internal.net.HttpResponse.createException(HttpResponse.java:188) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.AbstractScalarWebProtocol.execute(AbstractScalarWebProtocol.java:100) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebAvContentProtocol.getChannelDescriptors(ScalarWebAvContentProtocol.java:360) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebProtocolFactory.getChannelDescriptors(ScalarWebProtocolFactory.java:133) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.initializeTask(ScalarWebHandler.java:191) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.access$1(ScalarWebHandler.java:160) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler$2.run(ScalarWebHandler.java:152) [331:org.openhab.binding.sony:2.2.0.201711091019]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]
16:09:53.557 [ERROR] [.protocols.ScalarWebAvContentProtocol] - Exception occurred retrieving the content list for scheme ‘fav’ and source ‘fav:tv?id=4’: Illegal Argument
java.io.IOException: Illegal Argument
at org.openhab.binding.sony.internal.net.HttpResponse.createException(HttpResponse.java:188) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.AbstractScalarWebProtocol.execute(AbstractScalarWebProtocol.java:100) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebAvContentProtocol.getChannelDescriptors(ScalarWebAvContentProtocol.java:360) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebProtocolFactory.getChannelDescriptors(ScalarWebProtocolFactory.java:133) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.initializeTask(ScalarWebHandler.java:191) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.access$1(ScalarWebHandler.java:160) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler$2.run(ScalarWebHandler.java:152) [331:org.openhab.binding.sony:2.2.0.201711091019]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]

16:09:53.945 [ERROR] [.protocols.ScalarWebAvContentProtocol] - Exception occurring getting the playing content info: Display Is Turned off
java.io.IOException: Display Is Turned off
at org.openhab.binding.sony.internal.net.HttpResponse.createException(HttpResponse.java:188) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.AbstractScalarWebProtocol.execute(AbstractScalarWebProtocol.java:100) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.AbstractScalarWebProtocol.execute(AbstractScalarWebProtocol.java:86) ~[331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebAvContentProtocol.getChannelDescriptors(ScalarWebAvContentProtocol.java:787) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.protocols.ScalarWebProtocolFactory.getChannelDescriptors(ScalarWebProtocolFactory.java:133) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.initializeTask(ScalarWebHandler.java:191) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler.access$1(ScalarWebHandler.java:160) [331:org.openhab.binding.sony:2.2.0.201711091019]
at org.openhab.binding.sony.internal.scalarweb.ScalarWebHandler$2.run(ScalarWebHandler.java:152) [331:org.openhab.binding.sony:2.2.0.201711091019]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]

@Tomibeck I saw this in the log: “Can’t get text form - no public key”
isn’t the public key the access code in the thing config?

2019-06-29 16:03:47.075 [INFO ] [.internal.scalarweb.ScalarWebHandler] - Attempting connection to Scalar Web device...

==> /usr/share/openhab2/log/events.log <==
2019-06-29 16:03:47.189 [me.event.ThingUpdatedEvent] - Thing 'sony:scalar:7fb57bd3dec0' has been updated.

==> /usr/share/openhab2/log/openhab.log <==
2019-06-29 16:03:47.454 [INFO ] [nding.sony.internal.ircc.IrccHandler] - Attempting connection to IRCC device...

==> /usr/share/openhab2/log/events.log <==
2019-06-29 16:03:47.471 [me.event.ThingUpdatedEvent] - Thing 'sony:ircc:7fb57bd3dec0' has been updated.

==> /usr/share/openhab2/log/openhab.log <==
2019-06-29 16:03:47.807 [INFO ] [ding.sony.internal.ircc.IrccProtocol] - Command map already defined - ignoring: /etc/openhab2/transform/ircc-7fb57bd3dec0.map

==> /usr/share/openhab2/log/events.log <==
2019-06-29 16:03:47.814 [hingStatusInfoChangedEvent] - 'sony:ircc:7fb57bd3dec0' changed from OFFLINE (COMMUNICATION_ERROR): Error connecting to IRCC device (may need to turn it on manually): java.net.ConnectException: Connection refused (Connection refused) to ONLINE

==> /usr/share/openhab2/log/openhab.log <==
2019-06-29 16:03:47.816 [INFO ] [g.sony.internal.AbstractThingHandler] - Starting state polling every 30 seconds
2019-06-29 16:03:47.824 [INFO ] [g.sony.internal.AbstractThingHandler] - Starting state polling every 30 seconds
2019-06-29 16:03:50.326 [INFO ] [web.protocols.ScalarWebLoginProtocol] - Command map already defined - ignoring: /etc/openhab2/transform/scalar-7fb57bd3dec0.map
2019-06-29 16:03:51.864 [INFO ] [rotocols.ScalarWebAppControlProtocol] - Can't get text form - no public key
2019-06-29 16:03:54.041 [INFO ] [g.sony.internal.AbstractThingHandler] - Starting state polling every 30 seconds

Just got my system up and running and I’m getting the same thing (403 forbidden). I’m really hoping that this is an error in my code versus sony knocking that service out. I’ll be testing and trying to figure out - I’ll report back to you

I’m going to need you to PM me the full log if you would - those ‘exceptions’ really aren’t exceptions for you and aren’t the cause of the issue. However - from the exception message you are using an older version of the addon - I’d definitely upgrade to the latest to see if the issue has been fixed alread.

No - there is a separate encryption key for entering text into fields. That message is basically saying there is no public encryption key for the text form on the screen. Usually not an issue since the device probably doesn’t support that