Sony Devices Binding

Tags: #<Tag:0x00007f51dc8b7060>

(Knut) #644

Same thing here. Today I tried the WOL with SimpleIP. The magic packet was send but the tv didnt turn on:

2019-03-14 20:04:13.307 [DEBUG] [y.internal.simpleip.SimpleIpProtocol] - Sending WOL packet to FC:F1:52:A5:02:57 (
2019-03-14 20:04:13.308 [DEBUG] [y.internal.simpleip.SimpleIpProtocol] - Sending '*SCPOWR0000000000000001'
2019-03-14 20:04:14.072 [DEBUG] [] - Connecting to
2019-03-14 20:04:26.316 [DEBUG] [] - Connecting to
2019-03-14 20:04:38.320 [DEBUG] [] - Connecting to
2019-03-14 20:04:50.322 [DEBUG] [] - Connecting to
2019-03-14 20:05:02.325 [DEBUG] [] - Connecting to

Then it used my item defined with the WoL bindung and it turned on directly:

2019-03-14 20:07:20.828 [INFO ] [nhab.binding.wol.internal.WolBinding] - Wake-on-LAN packet sent [broadcastIp=, macaddress=fcf152a50257]
2019-03-14 20:07:21.470 [DEBUG] [] - Connecting to
2019-03-14 20:07:33.472 [DEBUG] [] - Connecting to
2019-03-14 20:07:45.476 [DEBUG] [] - Connecting to
2019-03-14 20:07:57.478 [DEBUG] [] - Connecting to
2019-03-14 20:08:08.424 [DEBUG] [larweb.ScalarWebDiscoveryParticipant] - Found Sony WebScalarAPI service: uuid:00000000-0000-1010-8000-fcf152a50257

Not a big thing. Using nhab.binding.wol.internal.WolBinding works good for me with some rules but if not needed it would be nice.

(Tim Roberts) #645

I think I spotted an error you two might be triggering - wait for the next version. I’m going to be gone for the next 5 days - so I’ll catch up when I get back…

(Knut) #646

I think chopping of last octet an replacing it with 255 will work in 99,9%. So i think this is totally fine.

Anyway an idea for some later optimization:
Maybe you can get a value from
The primary subnet of openhab can be defined there via Paper UI > Configuration > System Network Settings. With the IP and subnet mask the broadcast address can be calculated (sure you know this). On the downside i think its not required to set this so most users would not have done it. On the other hand its a dropdown value so maybe the information is there anyway.

(Knut) #647

With the new Version my Scalar thing is still not going online. Not much i can say about that at this moment so just a big log again. (14MB ziped to som KB). Zip-files are not allowed so after download rename it(delete “.log”).
SCALAR.7z.log (247.8 KB)

(Alexander Kluwe) #648

Ok it works only when I just turned off the TV. Otherwise after some time it doesn’t work “no route to Host”. Another problem is that the binding will forget the Mac adress and refresh value after some time. So I have created the TV within a. things file.

(Knut) #649

I cant see the “no route to host” error in my logs but it did not work for me too. To test it you have to turn off your tv for more than 5 minutes. You will see the binding is no longer online after that time. I even can hear my tv make a click sound. I think we wait to the next version.

In the meantime i use the integrated WoL Binding “WOL (Wake-on-LAN) Binding” (binding-wol1 - 1.13.0)

I defined an item like this:

Switch WoL_WZ_TV   "TV WoL"  <screen>  { wol="", autoupdate="false" }

I used autoupdate="false" because sending the WoL packet dosent mean the tv is really turned on. Maybe its unplugged or something. So after sending ON command to the item, wich triggers sending the WoL packet, it stays OFF.
To sync it with the real state of the tv read from the binding it use this simple rule:

rule "WoL_WZ_TV aktualisieren auf SonySimpleIP_Power.state"
	Item SonySimpleIP_Power changed 
	logInfo( "tv_wol.rules", "Rule 'WoL_WZ_TV aktualisieren auf SonySimpleIP_Power.state' triggered" )

This updates my WoL item when the tv is going ON or OFF even for instance if the tv remote is used.
Another rule helps me to send an OFF via the binding when i switch of my WoL item:

rule "WoL_WZ_TV zum Ausschalten nutzen"
	Item WoL_WZ_TV received command OFF  
	logInfo( "tv_wol.rules", "Rule 'WoL_WZ_TV zum Ausschalten nutzen' triggered" )

Works good.

(Andi) #650

Hi, thanks for the new binding. SimpleIP is working just fine. But i got problems with Scalar.
I got it registered with the 4-digit code, but since then it does not connect properly.
Can somebody support?

Attached i have a debug log (some seconds in normal logging, then switched to debug logging at some point)

sony_log.txt (556.2 KB)