Skip to content

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

examples: add RCA RC50A21S-4KSM (Android TV 9, Toptech/Zeasn, Realtek RTD2851P)

waltstuffa72f26af8c88
diff --git a/README.md b/README.md
index 43ee83405..1849afa16 100644
--- a/README.md
+++ b/README.md
@@ -222,6 +222,7 @@ Anker Nebula, BYINTEK, Epson, Formovie, Gadnic, JMGO, Magcubic, Portronics, Stel
| Portronics Beem 470 Smart LED Projector (Allwinner H713, 1 GB), India | Android 11 |
| PRISM+ Q65 Ultra 2026 QLED 4K AI Google TV (R10G, PRISMPLUS_FFM, MOKA, Realtek RTD2875 SoC, RTD6748 platform) | Google TV 14 |
| RCA AI PONT SA (Changhong, redwood, ISDB92RC; also sold as realme 40-inch and AIWA AW32B4SMG) | Android 14 |
+| RCA RC50A21S-4KSM, Zeasn home (Toptech firmware RTK2851P, Realtek RTD2851P, board mac6p) | Android TV 9 |
| Redmi TV (MiTV-ANTL0, starwars) | Android 5.1.1 (not Android TV) |
| Redmi TV (MiTV-MFTP0, alita), China firmware 23.2.10.6129 | Android TV 9 (CN build) |
| RockTek GB1 | Google TV 14 |
diff --git a/examples/README.md b/examples/README.md
index e772cd3d1..1772adbc9 100644
--- a/examples/README.md
+++ b/examples/README.md
@@ -102,6 +102,7 @@ on that firmware, grouped and commented. These are starting points: comment out
| `portronics-beem-470/` | Portronics Beem 470 Smart LED Projector (Allwinner H713, 1 GB), India | Android 11 | First Portronics list: HTC stock launcher/OTA/telemetry and app store, Allwinner Live TV/media/theme apps, stock YouTube replaced by SmartTube, AOSP phone/print/cell leftovers; casting/EShare kept; HOME key needs both setup flags, and Settings needs an explicit component because the firmware answers no ACTION_SETTINGS |
| `prismplus-q65-ultra-r10g/` | PRISM+ Q65 Ultra 2026 QLED 4K AI Google TV (R10G, PRISMPLUS_FFM, MOKA, Realtek RTD2875 SoC, RTD6748 platform) | Google TV 14 | Realtek partner customizer, Google partner setup and auto-installs, ambient mode, unused DTMB/ISDB/ATSC tuners, karaoke, preloaded apps; Max off by choice; keep com.realtek.dtv and com.realtek.tv.atv for inputs |
| `rca-ai-pont/` | RCA AI PONT SA (Changhong, redwood, ISDB92RC; also sold as realme 40-inch and AIWA AW32B4SMG) | Android 14 | Homwee store/tools (incl. chtvmanager) and installers, Anoki ACR, FAST channels (re-enabled by firmware at boot); keep partnercustomizer (crash-loops tv.service); 1 GB; AIWA variant notes (updaters kept, Live TVx back at every boot, config.json) |
+| `rca-rc50a21s-4ksm/` | RCA RC50A21S-4KSM, Zeasn home (Toptech firmware RTK2851P, Realtek RTD2851P, board mac6p) | Android TV 9 | Zeasn ad portal, weather service and store, partner auto-installs; userdebug build, no ADB prompt; Inputs pill opens RCA's own panel (`com.toptech.tvmenu/.input.InputActivity`) since nothing handles the channel VIEW intent (#805); Input key needs `handle_view_inputs` and `restore_key_services` (accessibility list cleared at every boot), not yet tested here; ~1.5 GB |
| `redmi-mitv-antl0/` | Redmi TV (MiTV-ANTL0, starwars) | Android 5.1.1 (not Android TV) | Mi push/web-content/cloud-control ads, TV Taobao, stock screensaver, OTA; needs `pm hide` instead of `pm disable-user`; startup-ad method depends on firmware and stock-launcher version, see the [L43M7-EA settings-only case](../docs/devices/xiaomi-l43m7-ea-antl0.md) |
| `redmi-mitv-mftp0/` | Redmi TV (MiTV-MFTP0, alita), China firmware 23.2.10.6129 | Android TV 9 (CN build) | CN-firmware Redmi, no Google apps: Mi analytics, tvqs, after-sales survey upload, cloud control, promo web container, shop plugin and store, preloaded apps, Mi Home off; `pm disable-user` works; **keep PatchWall enabled**: Home is a package-name allowlist like MiTV-AETP0, the `com.ts.launcher` application-ID build became Home and survived a reboot, do not run `build-and-install.sh` with defaults; startup ad off with `boot_ad_switch 0` on launcher 3.49.1601; `com.gitvdemo.video` is 银河奇异果 (iQIYI), kept; push service (installer whitelist), voice, casting, OTA, payments kept |
| `rocktek-gb1/` | RockTek GB1 | Google TV 14 | Provisional seven-package list: Android privacy-sandbox services, feedback and unused media apps; setupwraith and launcherx off only after a confirmed Home handover and Wi-Fi ownership check; [gear and Macro buttons restored](rocktek-gb1/README.md) through the device overlay |
diff --git a/examples/rca-rc50a21s-4ksm/README.md b/examples/rca-rc50a21s-4ksm/README.md
new file mode 100644
index 000000000..66063902b
--- /dev/null
+++ b/examples/rca-rc50a21s-4ksm/README.md
@@ -0,0 +1,95 @@
+# RCA RC50A21S-4KSM (Android TV 9, Toptech/Zeasn firmware, Realtek RTD2851P)
+
+RCA set sold with a Zeasn home screen (big RCA logo, Netflix/Claro video/Prime Video tiles, round icon dock),
+model `RC50A21S-4KSM`. Firmware `RTK2851P eng.tianju.20210703.181325`, a `userdebug` build on a
+Realtek RTD2851P (`rtd285o`, board `mac6p`), about 1.5 GB RAM. The Android model properties are generic
+(`SmartTV`), so match on the build id. Both halves work: the debloat list and the reference launcher as Home.
+Applied on 21 October 2026 on one set and used for two days since, through several reboots and power off/on.
+Not a longer soak yet.
+
+| File | What it is |
+|---|---|
+| `debloat.txt` | The 6 packages that were disabled, grouped and commented |
+| `config.json` | Inputs pill wired to RCA's own source panel, plus a placeholder dock; push it with `tools/theme.sh` |
+
+All commands run from the repo root, with the TV's IP in `TV_HOST`.
+
+## Turning ADB on
+
+Settings → Device Preferences → About → press OK on Build 7 times → back → Developer options → USB debugging.
+USB debugging alone opens network ADB on port 5555.
+
+This firmware is `userdebug` and `ro.adb.secure` is empty: **no "Allow USB debugging?" prompt appears, and any
+device on the network gets a shell while debugging is on.** Switch it off when you are done. On the test set,
+`settings put global adb_enabled 0` closed the port and it stayed closed after a restart
+(`tools/adb-closed.py <tv ip>` answers "refused").
+
+The TV took a new DHCP address after most reboots, and moved between Wi-Fi and Ethernet when a cable was
+plugged in, so read the IP again (Settings → Network) before reconnecting.
+
+## Install
+
+```bash
+TV_HOST=<tv ip> tools/disable.sh examples/rca-rc50a21s-4ksm/debloat.txt
+TV_HOST=<tv ip> STOCK_LAUNCHER=com.zeasn.rca.toptech launcher/build-and-install.sh
+TV_HOST=<tv ip> tools/theme.sh examples/rca-rc50a21s-4ksm
+```
+
+`disable.sh` skips the stock launcher while it still owns Home; run it once more after the launcher is in.
+Edit `dock_apps` in `config.json` before pushing it.
+
+## Inputs: use RCA's own panel
+
+`TvInputManager` lists HDMI 1-3, AV, VGA and YPbPr, but nothing on this firmware answers `ACTION_VIEW` on a
+passthrough channel URI the way a Live TV app would, so the launcher's HDMI rows do not switch input. Worse, any
+installed app that claims `vnd.android.cursor.item/channel` catches that intent instead: on the test set
+**ES File Explorer** (`com.estrongs.android.pop`, its "transfer station" activity) opened every time HDMI 1 was
+picked (#805).
+
+RCA's own source panel works: `com.toptech.tvmenu/.input.InputActivity` (action
+`com.toptech.tv.action.INPUT_ACTIVITY`) lists TV, AV, YPbPr, VGA, HDMI1 (ARC), HDMI2 and HDMI3 and switches
+correctly. `config.json` points `source_panel_service` at it and empties `live_tv_package`, so the Inputs pill
+opens that panel directly. This part is what the test set has run on for the two days.
+
+## The remote's Input (Fuente/Source) button: optional, not tested with the merged options
+
+The remote's key layout (`/system/usr/keylayout/venus_IR_input.kl`) maps scancode 768 to `KEYCODE_TV_INPUT`.
+`dumpsys window policy` routes it as a global key to `com.toptech.tvmenu/.receiver.GlobalKeyReceiver`, which does
+nothing once the Zeasn launcher is not Home. The Inputs pill works without any of the following.
+
+To get the button back, `InputKeyService` has to catch the key, and three things on this firmware get in the way:
+
+1. **Nothing answers `com.android.tv.action.VIEW_INPUTS`**, which is what the service starts, so the key is
+ swallowed. `"handle_view_inputs": true` in `config.json` (#730) makes the launcher answer it with its Inputs
+ menu, which with this folder's `config.json` should open RCA's panel.
+2. **The firmware empties `enabled_accessibility_services` and sets `accessibility_enabled` to 0 at every boot**,
+ and Settings has no Accessibility screen to turn the service back on. `"restore_key_services": true` with
+ `RESTORE_KEY_SERVICES=1` at install (#670) puts it back when Home starts, as long as the firmware empties the
+ list before the service is bound (see the author's note in #670).
+3. **Key repeat stops while the service filters keys**: a held volume button steps once per press (with the service
+ off it steps continuously; #763). `"key_filter": false` (#770) brings repeat back but then the service no
+ longer catches the Input key, so on this set it is one or the other. The remote's volume buttons are not
+ `KEYCODE_VOLUME_*`: they arrive as `KEYCODE_BUTTON_7` (up, scancode 766) and `KEYCODE_BUTTON_6` (down, 765),
+ global keys that `com.realtek.tv.settings` turns into volume steps.
+
+The test set got the button working with local launcher changes that did the same as 1 and 2 by other means, plus
+a volume repeat inside the service for 3. The merged `handle_view_inputs` and `restore_key_services` have **not**
+been run on this set, so treat this section as a starting point. Install with the service on:
+
+```bash
+TV_HOST=<tv ip> INPUT_KEY_SERVICE=1 RESTORE_KEY_SERVICES=1 STOCK_LAUNCHER=com.zeasn.rca.toptech launcher/build-and-install.sh
+```
+
+## Other firmware quirks
+
+- **ES File Explorer loses its data on every Home press.** The system services code on this build
+ (`/system/framework/oat/arm/services.vdex`) contains the string `com.estrongs.android.pop`, and the log shows
+ `ActivityManager: Force stopping com.estrongs.android.pop ...: clear data` between the firmware's own
+ `HOME44444444` / `HOME5555555555` lines. Nothing in this folder causes it.
+- Settings has no Accessibility screen.
+
+## Undo everything
+
+```bash
+TV_HOST=<tv ip> tools/restore.sh examples/rca-rc50a21s-4ksm/debloat.txt com.zeasn.rca.toptech
+```
diff --git a/examples/rca-rc50a21s-4ksm/config.json b/examples/rca-rc50a21s-4ksm/config.json
new file mode 100644
index 000000000..5851b1450
--- /dev/null
+++ b/examples/rca-rc50a21s-4ksm/config.json
@@ -0,0 +1,10 @@
+{
+ "dock_apps": ["com.google.android.youtube.tv", "com.netflix.ninja", "com.amazon.amazonvideo.livingroom", "com.android.vending"],
+ "live_tv_package": "",
+ "source_panel_service": "com.toptech.tvmenu/.input.InputActivity",
+ "source_panel_action": "com.toptech.tv.action.INPUT_ACTIVITY",
+ "columns": 4,
+ "rows_below_dock": 0,
+ "background_color": "#000000",
+ "wallpaper": false
+}
diff --git a/examples/rca-rc50a21s-4ksm/debloat.txt b/examples/rca-rc50a21s-4ksm/debloat.txt
new file mode 100644
index 000000000..be2d9e6db
--- /dev/null
+++ b/examples/rca-rc50a21s-4ksm/debloat.txt
@@ -0,0 +1,37 @@
+# RCA Android TV, RC50A21S-4KSM (Toptech/Zeasn firmware, Realtek RTD2851P)
+# Android TV 9 (API 28), firmware RTK2851P eng.tianju.20210703.181325 (userdebug, release-keys)
+# ro.product.model=SmartTV ro.product.device=SmartTV ro.product.manufacturer=Q010
+# ro.board.platform=rtd285o ro.product.board=mac6p ~1.5 GB RAM, armeabi-v7a userspace
+# Fingerprint: Realtek/RealtekATV/RealtekATV:9/RTK2851P/tianjunyong07031813:userdebug/release-keys
+# The model properties are generic (SmartTV / SMARTPHONE): match on the build id and board, not the name.
+#
+# Apply: TV_HOST=<tv ip> tools/disable.sh examples/rca-rc50a21s-4ksm/debloat.txt
+# Undo: TV_HOST=<tv ip> tools/restore.sh examples/rca-rc50a21s-4ksm/debloat.txt com.zeasn.rca.toptech
+# Everything is DISABLED, not uninstalled. Comment out any line you want to keep.
+#
+# Stock launcher: com.zeasn.rca.toptech (Zeasn). Android's FallbackHome is the only other HOME.
+# No Live TV app with a leanback entry point: tuner and inputs live in com.toptech.tvmenu (keep it).
+# The saved Wi-Fi network belongs to android.uid.system; no setupwraith on this build.
+#
+# Leave alone: com.toptech.* (tvmenu = input panel and TV player, tv.service, keyboard_seven,
+# setupwizard, systemupdate, tvfactory, factorytools), com.realtek.* (dtv, tv.atv, tv.passthrough = HDMI/AV/
+# VGA/YPbPr inputs, providers.tv), com.hikeen.actiontest. Do not launch the factory packages.
+# Kept by choice on the test set: Google Assistant (katniss), firmware updates (com.toptech.systemupdate),
+# AirPlay/EShare/DLNA (com.ecloud.*), Miracast (com.rtk.android.miracast), USB media player, photo screensaver.
+#
+# Applied 2026-10-21 on one set and used for two days, through several reboots and power off/on: nothing came
+# back enabled, Home stayed on the reference launcher, Wi-Fi and Ethernet reconnect. Not a longer soak yet.
+# See README.md in this folder for the Inputs panel, the Input key and the ADB notes.
+
+# Zeasn ad portal, store and background services
+com.zeasn.deviceportal.asdprovider.toptech # ad/portal service; starts at boot, can install packages (~69 MB)
+com.zeasn.services.general # Zeasn "weather" service; starts at boot, reads logs (~69 MB)
+cn.zeasn.toptech2851.rca.vstoresubclient # Zeasn app store; Google Play stays
+
+# Partner auto-installs and unused services
+android.autoinstalls.config.realtek.device # Play auto-installs of partner apps
+com.android.printspooler # printing
+
+# Stock launcher: disable only once the reference launcher owns Home (build-and-install.sh with
+# STOCK_LAUNCHER=com.zeasn.rca.toptech does it in the right order)
+com.zeasn.rca.toptech # Zeasn launcher with promo rows