Closed DennisFre closed 1 month ago
I guess the problem is not the remote but the android tv remote protocol. The python library used by the intergration only support a power (toggle) KEYCODE_POWER here we see that this command is used.
Maybee KEYCODE_SLEEP and KEYCODE_WAKEUP would be the better choice?
Also seeing the issue and think it might be causing some weirdness in activity groups but I'm yet to try and get to the root cause of that.
When I still had a Sony Android TV (XE9005) I had no problems powering it on and off via the Android TV integration. Maybe it's a network or setting issue? Or just newer Android TV versions have this problem as my TV was from 2017 running Android TV 9.
I don't think my issue is related to the power toggling rather than being discrete. I did a quick check in the code and it appears to rely on the imported package telling it the state rather than calculating it itself.
I haven't had a chance to look any further, however having discrete power options would be easier when trying to fix things if they get out of sync in some way.
The current power state is now considered before sending the power toggle command. Unfortunately the Android TV remote protocol only defines a power toggle command. Other commands like SLEEP and WAKEUP don't work on every device. With the newly introduced device profiles and the keycode testing function, we can create device specific profiles where this commands are supported.
The new Android TV integration version will soon be released in beta channel.
Included in the just released beta firmware 1.7.9 and will be part of the next public release.
Fixed in release 1.7.12
Is there an existing issue for this?
Description
If I add a Android TV Integration im not able to discrete turn on and off the TV. It is just every time a on/off toggle.
How to Reproduce
Expected behavior
System version
1.4.8
What part of the system affected by the problem?
Integration
Additional context
No response