[Release] Sony Bravia TV Rest Control

Did avyone ever resolve this issue... super annoying. I saw references to it in earlier posts but no resolution. Even if there were just a way to supress the error I'd be ok with that.

I just disabled that part of the code in the end as it annoyed me and I did not need that bit.

1 Like

Its been awhile since i have been on here. My only Sony TV has been off the wall (on wifi, without driver update) for about 12 months while renovating, starting new job, having baby, so i haven't kept up with this. I did get a few updates from Sony that could cause issues.

So the error that you have shown is a network error where the hubitat calls cannot reach the Sony API. Im not explicitly logging this error as its built in to the hubitat (to my knowledge). The networking stuff inside the Sony endpoint may have some issues that cause this to happen occasionally. In my years of having the rest API polled, it showed up about 3 times, but I never had my status not update (and i polled every minute to set background lights). I'm not aware what @BorrisTheCat did to purge the errors.

Hi Angus_M what was your final rule to get the Sony TV to toggle mute and unmute, every other time.

Yes, very simple...

image

Thanks, is this mute and unmute, or just power.

That was power, this is mute:

image

Thanks for the reply. I'll just disable that part of the code.

I believe I had a similar issue - I have a RM 5 rule to turn on an LED backlight (via a Sonoff Zigbee plug named Backlight) when my Sony TV, an XBR-55X930D, turns on and to turn off the backlight when the TV turns off:

It was intended to be triggered anytime the TV on/off state changed (I have the Refresh Interval set to 1 min), but I found that I was getting a changed rule trigger every time the TV on/off state was queried, even if no power state had changed. I edited the driver at line 224 to check the current state.devicepower against the query response before issuing an event, like so:

With this change I got the behavior I was looking for: backlight comes on when TV turns on, doesn't turn off until the TV does. Note that I have absolutely zero Groovy coding experience, so @ajones was this the appropriate way to handle the superfluous devicepower state triggers? It appears that event triggers based on querying other TV parameters follow the same model as the original on/off event code and may exhibit a similar issue.

4 Likes

Nice improvement, thank you!

I guess this is where the TV is off and so it can’t connect to the IP address? I also get this error every minute when the TV is off.

Even when the TV is "off" it is actually just asleep, still fully responsive to remote control events sent over the network if you have Settings > Network > Home Network Setup > IP Control > Simple IP Control enabled.

Incredibly it also continues to run AndroidTV apps in the background while in standby too. I have tinyCAM running cameras on mine and it continues to send motion and object detection messages to HE even while “off”. I freaking love my Sony TV.

Hi @ajones

Where i can find IR Hex Command for Sony Bravia?

I just got a platform message that a TV using this driver is generating “excessive events”. It was turned on at the time but in standby. Expected? Could/should it generate fewer? Happy to share more details, but I imagine easy to reproduce.

Just installed this. I'm thinking it could come in handy, All commands work except the On command. Off works, but once off, On does nothing. (A80J)

ConnectTimeoutException

Key Press Action - TVPower turns it on, but I was hoping for discrete On.

(Edit) Solved - needed Simple IP Control enabled.

are you using this as a button template in hubitat dashboard?

Hello @ajones

We just switched over to YouTube TV so I added it to my local driver code for the Launch App function, can you add it to the next driver update for everyone?

Line 47: "YouTube TV"
Line 587: if (appname == "YouTube TV") { app = "com.sony.dtv.com.google.android.youtube.tvunplugged.com.google.android.apps.youtube.tvunplugged.activity.MainActivity"}

Thanks

Is this still being developed? Or is there a better driver out there?

I don't know if it is still being developed, but it did work for me. However I decided to get rid of it because I discovered that it prevents the TV from entering "deep sleep" mode, resulting in a standby power consumption of 23 watts, vs less then 1-watt once I removed this device from Hubitat.

I suspect the issue is caused by the periodic polling, but I can't be certain.

Sharing this in case it is helpful to anyone.

marc

1 Like