This is how you can connect your Android TV devices using ADB to your Home assistant setup. This will require developer access to your device which can be easily activated.
- In order to activate a developer mode in your device, go into settings->build number -> press 8 times until a message showing you are now a developer will show up. Close it.
- Make sure your device has an internal static IP so you can configure it in your homeassistant configuration.yaml
- Add to configuration.yaml:
media_player:
- platform: androidtv
name: Cellcom TV
host: 192.168.1.15
- Restart home assistant
- Search your newly created entity with the name that you gave it.
- Add it to the UI
- If you can’t control certain buttons – the solution is simple; Create a script and trigger it through a UI button with the following data:
entity_id: media_player.cellcom_tv
command: HOME # Or any other command (this script will trigger the home button)
Home assistant integration page:
https://www.home-assistant.io/integrations/androidtv