Sony Devices Binding

I just posted number 2 for today:

  1. Delete the ircc map file to allow it to recreate (should remove the “STR:” parts in the commands - let me know if it doesn’t)
  2. Included a new channel - viewing#zone2source that should contain the source for zone2

Could you also reply with the exact directions to put the AV into pairing mode (want to include it in the documentation

Latest testing file should fix your issue - let me know if it doesn’t

Stuliet - download the latest from the openhab2-addons sony thread - should be able to connect now (you need to put the AV into registration mode as documented by Oliverk for it to properly pair)

Unfortunately not:

2017-02-14 18:22:13.034 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-14 18:22:47.027 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-14 18:23:21.138 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-14 18:23:55.182 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-14 18:24:29.394 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-14 18:25:03.505 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring

I used “sony-binding-2017-02-13-2”

Andi,

Download the latest “sony-binding-2017-02-14-1” and try that one

Tim

the new ircc map file was created, removed the STR: parts and is working fine!

2017-02-14 20:12:42.829 [DEBUG] [ding.sony.internal.ircc.IrccProtocol] - Transformed VolumeUp with map file 'ircc-5f9ec1b3-ed59-1900-4530-5453edf73098.ma
p' to ircc:AAAAAgAAADAAAAASAQ%3D%3D

here the exact directions to put the Sony STR-DN1030 into pairing Mode:
Settings/Network/Media Remote Device/Start Registration

Thanks Tim & Oliver, this is working for me with the sony-binding-2017-02-13-1.jar binding. Now to work out ho to use it!

Stuart,

Download the 2017-02-14-1 or the 2017-02-13-2 to get the latest changes

BTW - which model do you have? Nevermind - you have the STN-1050. Any chance you can turn on debug and post what the “getStatus” URL is returning?

Tim

No problem, downloaded and installed sony-binding-2017-02-14-1.jar

Is this the output you are looking for?

2017-02-14 20:36:26.855 [DEBUG] [inding.sony.internal.net.HttpRequest] - 209 * Sending client request on thread ESH-thingHandler-3
209 > GET http://192.168.1.53:50001/cers/getStatus
209 > Connection: close
209 > User-Agent: OpenHab/Sony/Binding
209 > X-CERS-DEVICE-ID: MediaRemote:00-11-22-33-44-55
209 > X-CERS-DEVICE-INFO: OpenHab/Sony/Binding

2017-02-14 20:36:27.465 [DEBUG] [inding.sony.internal.net.HttpRequest] - 210 * Client response received on thread ESH-thingHandler-3
210 < 200
210 < Connection: close
210 < CONTENT-LENGTH: 152
210 < CONTENT-TYPE: text/xml; charset="utf-8"
210 < X-AV-Physical-Unit-Info: pa="STR-DN1050"
210 < X-AV-Server-Info: av="5.0"; cn="Sony Corporation"; mn="STR-DN1050"; mv="1.00"
<statusList><status name="viewing"><statusItem field="source" value="SAT/CATV" /><statusItem field="zone2Source" value="SOURCE" /></status></statusList>

Yep - that should work just fine with that binding.

Still that log messages :frowning:

2017-02-15 16:44:36.661 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-15 16:45:09.857 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-15 16:45:43.079 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-15 16:46:16.261 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-15 16:46:49.445 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring
2017-02-15 16:47:22.625 [INFO ] [y.internal.simpleip.SimpleIpProtocol] - Response took too long - ignoring

And you’re positive that you are using the correct jar now (not the zip)? If so, search you’re system to see if the old one is still laying around. The reason I ask - I changed the text on that message and I don’t see the text change I made…

Hmm I am not sure, i stopped oh2 deleted the old jar file, dropped the new one, set the persmissions and restarted oh2:

Where else could be an old jar that is loaded instead of this one?

Hi Tim! I noticed yesterday and today that the Sony went suddenly down and is shown as offline in PaperUI. OFFLINE - COMMUNICATION_ERROR Error connecting to IRCC device (may need to turn it on manually)

It seems that the binding suddenly stops polling the status from the Sony AV.
yesterday at 23:51 the last GET http://192.168.205.46:50001/cers/getStatus in the log file but no http 200 response.

afterwards the binding starts the discovery process over and over again until this morning:

openhab.log
2017-02-15 11:15:07.876 [DEBUG] [nding.sony.internal.ircc.IrccHandler] - exception: Premature end of file. org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 1; Premature end of file.

event.log
2017-02-15 11:15:07.891 [hingStatusInfoChangedEvent] - 'sony:ircc:5f9ec1b3-ed59-1900-4530-5453edf73098' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Error connecting to IRCC device (may need to turn it on manually)
attached the detailed logs… http://pastebin.com/um410x8H

when i restarted the bundle this evening, the Sony comes up online immediately. Any idea for this behavior?

Andi,

Seems like that is good - just to make sure - could you download the latest from today (2017-02-16) and give that a try?

Tim

Oliver,

Three things of note here:

  1. Go point on the discovery process. I was re-running device verification everytime the sony device sent out a discovery result packet. Latest version will change that to only run verification when it’s being added to the inbox.
  2. The lack of a retry, I think, is a side affect to the two phase authentication process I had (it wouldn’t retry if you were in phase 1 because it would cancel the registration attempt). As a quick, temporary test - the latest version will only retry after going online (you just need to make sure it goes online when you start it). I need to think through how to properly handle the situation however (ie identify a two phase authentication and not retry during it).
  3. I still say there is something funky going on in your network or the AV. I understand the pcaps were from a mirroring process but even they showed requests being sent with no replies occasionally (and a lot of retries and fragments). Might be something you want to investigate on your side.

At any rate, try the latest I posted today to see if they help (and remember - you’ll need to restart if it doesn’t go online immediately - after that the retires should kick in).

Tim

Hi Tim, sorry an old version was indeed still active. Uninstalling in the karaf console and then dropping the new jar file did the trick. Now I have this log entries, which seems to be the changed message you meant:

2017-02-16 16:07:58.454 [WARN ] [y.internal.simpleip.SimpleIpProtocol] - Unparsable response ‘’ to command ‘*SEPIPI################’
2017-02-16 16:08:24.116 [WARN ] [y.internal.simpleip.SimpleIpProtocol] - Unparsable response ‘’ to command ‘*SEPIPI################’
2017-02-16 16:08:57.981 [WARN ] [y.internal.simpleip.SimpleIpProtocol] - Unparsable response ‘’ to command ‘*SEPIPI################’
2017-02-16 16:09:31.909 [WARN ] [y.internal.simpleip.SimpleIpProtocol] - Unparsable response ‘’ to command ‘*SEPIPI################’
2017-02-16 16:10:05.909 [WARN ] [y.internal.simpleip.SimpleIpProtocol] - Unparsable response ‘’ to command ‘*SEPIPI################’

Interesting - what model of tv do you have again? Do you know if it support picture-in-picture?

I have a KD-49XD7005 and i think it does not support pip because i cannot find the feature in the menus/manual and it does not react to the pip functions in your binding.

Try the latest one I just posted - should fix that issue…