How to help with state detection!
See original GitHub issueState detection diagnostics
Assuming you’re using the Home Assistant Android TV component, here’s how you can help improve state detection.
This package determines the state in the AndroidTV.update
/ FireTV.update
methods using a collection of properties and reports that state to Home Assistant. You can see what those properties are by using the HA service androidtv.adb_command
with "GET_PROPERTIES"
as the command
argument – they will be logged at the INFO level and they will be stored in the media player’s adb_response
attribute (HA 0.94+), which can easily be viewed on the States tab. You can read more about the androidtv.adb_command
service at the bottom of the Android TV documentation.
The state detection logic will differ depending on the app. So open an app, send the "GET_PROPERTIES"
command a few times while it’s idle / on standby, playing, and paused, and try to figure out a better way to determine the state. Pull requests are welcome!
Issue Analytics
- State:
- Created 5 years ago
- Comments:19 (12 by maintainers)
Top GitHub Comments
‘Unavailable’ means that the ADB connection is not intact. Since HA can’t turn the device on, I think unavailable is the appropriate state. But that has to do with the Home Assistant component, not this package.
This issue needs to be done first: https://github.com/JeffLIrion/python-androidtv/issues/255
After that’s done, it shouldn’t be too hard to customize the command used the get the HDMI input and the code that processes the result.