-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sony TV HDMI input detection #227
Comments
There’s a method for getting device properties: python-androidtv/androidtv/basetv/basetv_sync.py Lines 185 to 193 in 88dab23
Rather than simply returning the dictionary of device properties, I think it should also store that dictionary. Then other methods could check the device properties and adjust their ADB commands accordingly, similar to how Google TV support is handled. For example, from
|
With the latest changes that I made, you can customize commands based on the device info. For example, see here:
You could add a |
@axxelh I checked out your suggested command to obtain the HDMI port number, which worked like a charm! Although the expected On my Sony Bravia KD-55XD7005 were the following hardware definitions, mapped to input using the respective TV Input Manager service intent.
In case you are interested, here is my proposed command, as in the linked pull request (66840c2), to obtain hardware identifier for both Sony TV (com.sony.dtv.tvinput.external) and other devices (com.mediatek.tvinput). dumpsys activity starter | grep -E -o '(ExternalTv|HDMI)InputService/HW[0-9]' -m 1 | grep -o 'HW[0-9]' |
@axxelh @JeffLIrion This has been addressed in v0.0.58 with the changes from #236. |
Issue 202 added HDMI input info, but that doesn't appear to work on current Sony Android TV implementations.
This command appears to work on my X950H, returning just the port number (ports are 1 indexed, when the routing is 0x0000 internal apps are in use).:
'dumpsys hdmi_control | grep -o 'mActiveRoutingPath: 0x[1-9]' | grep -o [1-9]'
There are several other fields in dumpsys that could be used, but this seemed cleanest to me.
Not sure what the right pattern is for multiple variants of CMD_HDMI_INPUT or detection of subtypes of Android TV so I'm not proposing a patch.
The text was updated successfully, but these errors were encountered: