Skip to content

Debloat any Android or Google TV over Wi-Fi and get an Apple TV-style home.

examples: TCL 55C655 (Italy) as a second unit of tcl-55p7k (G10 AS16), remote keycodes

Federico Ferretti20b6bac83e14
diff --git a/docs/watch-next.md b/docs/watch-next.md
index 7308d61a6..96d66c647 100644
--- a/docs/watch-next.md
+++ b/docs/watch-next.md
@@ -44,6 +44,14 @@ and preview channels. They live in the TV provider, behind `TvContract.WatchNext
Music"). Stremio (`com.stremio.one`) published none either; it keeps a preview channel named "Continue
Watching" whose rows carry `last_playback_position_millis` and `duration_millis` but no date column at all, so
they cannot be sorted or aged by time.
+- **Seen on a TCL 55C655** (G10, Google TV 12, `STT2.230203.001 AS16`), the same kind of probe with launcherx still
+ enabled: 34 Watch Next rows, RaiPlay (`it.rainet.androidtv`) 17, DAZN 10, Prime Video 5 and Netflix 2; Disney+
+ and Mediaset Infinity, both installed, had none. The newest four were the first four cards of Google TV's own
+ Continue watching row, in the same order, so on this set the stock row comes from the local table. Every poster
+ was `https://` (raiplay.it, Netflix's nflxso.net, Amazon's image CDN), and some RaiPlay rows had none. RaiPlay
+ often puts a tagline in `title` instead of the show's name ("Ogni giorno un nuovo episodio" for one daily
+ series), so a text-only card can be unreadable. The DAZN rows were channels, `watch_next_type` 2, last engaged
+ 433 days before. Preview programs: DAZN 55, Prime Video 30, TCL `channelplus` 30, Netflix 16, YouTube 7.
Source: `createSqlParams()` in `packages/providers/TvProvider/src/com/android/providers/tv/TvProvider.java`
(AOSP) holds the `READ_TV_LISTINGS` and `searchable` logic; both permissions are defined in that
diff --git a/examples/tcl-55p7k/README.md b/examples/tcl-55p7k/README.md
new file mode 100644
index 000000000..c066a7901
--- /dev/null
+++ b/examples/tcl-55p7k/README.md
@@ -0,0 +1,56 @@
+# TCL 55P7K / 55C655 (G10, Google TV 12)
+
+Notes from the second unit, a **TCL 55C655** (2024, Italy) on the same build as the 55P7K:
+`G10_4K_GB`, `STT2.230203.001 AS16`, Realtek RTD2875P, Bluetooth remote `BT_RC833_U1` (vendor `0x0417`, product
+`0x0304`). It ran `debloat.txt` with the streaming apps, Alexa and T-Solo kept, plus the extras at the end, for a
+day and two reboots, with the Clean Your TV launcher as Home and `HomeKeyService` on
+(`launcher/build-and-install.sh` with `HOME_KEY_SERVICE=1`).
+
+## Order that worked
+
+- `tools/disable.sh` skipped `android.autoinstalls.config.google.gtvpai` on the first run: its `dumpsys` has no
+ permission block for the input-driver check. With Live TV and HDMI checked on the real remote after a reboot,
+ `TVINPUT_ALLOW=1` disabled it.
+- The saved Wi-Fi network already belonged to `android.uid.system` (`dumpsys wifi | grep -o 'cname=[^ ]*'`), so
+ setupwraith went with launcherx in one run, with no re-join.
+- With launcherx still enabled, `build-and-install.sh` stops at its Home check (Home still resolves to launcherx),
+ before it turns the key helper on. Disabling setupwraith and launcherx in one `disable.sh` run then hands Home to
+ the launcher; run the install script again for `HomeKeyService`.
+
+## Remote buttons
+
+With launcherx disabled the app buttons do nothing: TCL sends its own keycodes and only launcherx answered them.
+`HomeKeyService` brings them back from `app_keys` and `settings_key_keycodes` in `config.xml`. Scancodes from
+`getevent -lt`, names from `/system/usr/keylayout/Generic.kl` (the remote's own `Vendor_0417_Product_0304.kl` is not
+readable from the shell), numbers from `KeyEvent.keyCodeFromString` run on the TV through `app_process`. Every row
+was checked with the real remote.
+
+| Button | Scancode | Name | Keycode | `app_keys` entry used |
+|---|---|---|---|---|
+| YouTube | 245 | `TCL_YOUTUBE` | **4065** | `4065:com.google.android.youtube.tv`; this unit used `4065:org.smarttube.stable` |
+| Netflix | 242 | `TCL_NETFLIX` | **4062** | `4062:com.netflix.ninja` |
+| Prime Video | 752 | `TCL_PRIMEVIDEO` | **4099** | `4099:com.amazon.amazonvideo.livingroom` |
+| TCL Channel | — | `TCL_QUICK_MENU` | **4020** | `4020:com.tcl.tv` (Live TV) |
+| Guide | 365 | `TCL_EPG` | **4001** | `4001:com.tcl.tv` and `front:4001:guide:com.tcl.tv`: Live TV, then its guide |
+| TCL Home | 204 | `TCL_DASHBOARD` | **4137** | `4137:com.gathin.tvhome/.QuickSettingsActivity` (the launcher's panel) |
+| Web | 651 | `TCL_BROWSEHERE` | **4159** | any app; this unit has no browser and used `4159:com.esaba.downloader` |
+| Settings (gear) | 233 | `NOTIFICATION` | **83** | `settings_key_keycodes` 83 |
+| Profile (person icon) | 653 | `PROFILE_SWITCH` | 288 | not mapped: Google TV profiles went with launcherx |
+
+- **YouTube is 4065 here, not 190** (`KEYCODE_BUTTON_3`, the Chromecast and G08 value): an entry for 190 does nothing.
+- **TCL Home** still opens TCL's own side panel (`com.tcl.dashboard`) with no entry, but its user icon leads to
+ `com.tcl.usercenter`, which the list disables; this unit gave the button to the launcher's panel instead.
+- **Web** opens BrowseHere on sets that have `com.tcl.browser`. This one does not: with `com.tcl.interactive`
+ disabled, a press only makes `com.tcl.tv` retry `tcl_tias_tbrowser` for about 13 seconds, then stop.
+- Home, Home held (`3:home` plus `hold:3:com.gathin.tvhome/.QuickSettingsActivity`), Input, D-pad and the
+ microphone work. The Assistant answers voice with launcherx disabled.
+- **Price:** with `HomeKeyService` filtering keys, Volume Up held moves one step per press, as on the TCL G09
+ (`docs/devices/tcl-55p71b-g09-key-repeat.md`).
+- The notification panel and Google TV profiles were launcherx's and are gone.
+
+## Power-on
+
+- From standby (the remote's power button) the set resumes where it was: it never really shuts down.
+- After a full reboot the firmware brings `com.tcl.tv` to the front about seven seconds after Home starts
+ (`logcat -b events | grep wm_set_resumed_activity`). This unit kept that; `power_on_home` would send it back to
+ Home.
diff --git a/examples/tcl-55p7k/debloat.txt b/examples/tcl-55p7k/debloat.txt
index c7ea65d47..81e2fe8dd 100644
--- a/examples/tcl-55p7k/debloat.txt
+++ b/examples/tcl-55p7k/debloat.txt
@@ -2,6 +2,10 @@
# Android 12 (Google TV), firmware STT2.230203.001 AS16
# Same G10 platform and build as tcl-g10-google-tv/, but with Middle East preloads (OSN+, Disney+ MEA,
# iQIYI, Shahid) and nothing disabled at the factory: logkit, Samba TV ACR and ttvs all ship ENABLED.
+# Second unit: TCL 55C655 (2024), Italy, same build (G10_4K_GB, STT2.230203.001 AS16, BT_RC833_U1 remote).
+# Same factory state; it ran everything above except the streaming apps, Alexa and T-Solo (kept by choice)
+# plus the extras at the end, for a day and two reboots. No com.tcl.browser and no com.tcl.hotelmenu on it.
+# Remote buttons, the Web key and power-on on that unit: README.md.
#
# Apply: TV_HOST=<tv ip> tools/disable.sh examples/tcl-55p7k/debloat.txt
# Undo: TV_HOST=<tv ip> tools/restore.sh examples/tcl-55p7k/debloat.txt com.google.android.apps.tv.launcherx
@@ -63,3 +67,11 @@ com.osn.go # OSN+
com.iqiyi.i18n.tv # iQIYI
com.spotify.tv.android
com.google.android.videos # Google TV / Play Movies
+
+# Extras, disabled on the 55C655 unit (Italy)
+com.tcl.UpdatePeripheral # TCL soundbar firmware updater; keep it if a TCL soundbar is connected
+com.android.printspooler
+com.google.android.syncadapters.calendar
+com.google.android.onetimeinitializer
+com.google.android.youtube.tvmusic # YouTube Music
+com.google.android.play.games # Play Games
diff --git a/examples/tcl-55p7k/tv.json b/examples/tcl-55p7k/tv.json
index df8bd4df9..1c8ac7db8 100644
--- a/examples/tcl-55p7k/tv.json
+++ b/examples/tcl-55p7k/tv.json
@@ -1,6 +1,6 @@
{
- "tv": "TCL 55P7K, Middle East (G10, G10_4K_GB, Realtek RTD2875P)",
+ "tv": "TCL 55P7K, Middle East (G10, G10_4K_GB, Realtek RTD2875P); also TCL 55C655, Italy (same build)",
"os": "Google TV 12",
"brand": "TCL",
- "notes": "Same G10 build as `tcl-g10-google-tv/` but logkit, Samba TV ACR and ttvs ship enabled; TCL Channel, push messages, TGuard, T-Solo, Alexa, hotel/demo; OSN+, Disney+ MEA, iQIYI off by choice; setupwraith before launcherx; Settings key is KEYCODE_NOTIFICATION, Web key 4159; TCL Audio Only turns the panel off with sound playing"
+ "notes": "Same G10 build as `tcl-g10-google-tv/` but logkit, Samba TV ACR and ttvs ship enabled; TCL Channel, push messages, TGuard, T-Solo, Alexa, hotel/demo; OSN+, Disney+ MEA, iQIYI off by choice; setupwraith before launcherx; Settings key is KEYCODE_NOTIFICATION, Web key 4159; [remote keycodes](tcl-55p7k/README.md) for Netflix, YouTube, Prime, Guide and TCL Home; TCL Audio Only turns the panel off with sound playing"
}