Skip to content

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

docs: a second MiTV4-ANSM0 (Mi TV 4A 50", build 3390) and a MiTV4A cross-check (#1185)

Gathin2382ede78d4975
diff --git a/docs/devices/xiaomi-mitv4-ansm0.md b/docs/devices/xiaomi-mitv4-ansm0.md
index cd17ca8a8..7a3db840c 100644
--- a/docs/devices/xiaomi-mitv4-ansm0.md
+++ b/docs/devices/xiaomi-mitv4-ansm0.md
@@ -44,3 +44,69 @@ application-details intent, so 应用信息 may not open.
Voice on the remote, 米家, 云视听小电视, system update, the cleaner, the HDMI player,
settings, Sogou IME and the Xiaomi account were kept.
+
+## A second set: Mi TV 4A 50" (MiTV4-ANSM0, build 3390)
+
+From @xialeizhou77's report in #1185: a 小米电视4A 50英寸, also `MiTV4-ANSM0` / `xmen`, Android 6.0.1 (API 23),
+build `3390`, stock PatchWall from firmware 1.3.130. The same refusals as above, so no list here either.
+
+What the shell user (uid 2000, groups `shell input log adb sdcard_rw sdcard_r net_bt_admin net_bt inet
+net_bw_stats`) may not do on this build:
+
+| Command | Result |
+|---|---|
+| `pm disable-user --user 0 <pkg>`, `pm disable`, `pm disable-until-used` | `SecurityException: Permission Denial: attempt to change component state` |
+| `pm hide <pkg>` | `SecurityException: Neither user 2000 nor current process has android.permission.MANAGE_USERS.` |
+| `pm trim-caches` | `SecurityException: ... has no android.permission.CLEAR_APP_CACHE.` |
+
+So `tools/disable.sh` cannot run (it needs `pm disable-user`) and neither can `tools/restore.sh` (`pm enable`).
+Android 6 also has no `cmd` binary, so `cmd package set-home-activity` and `cmd notification allow_listener` do
+not exist. This repo stays disable-only, so there is no supported debloat route on this generation.
+
+**Keep these, whatever else you try on this firmware:**
+
+- `com.sohu.inputmethod.sogou.tv`: the only keyboard; without it no search field can be typed into.
+- `com.xiaomi.mitv.tvpush.tvpushservice`: carries `GetInstallerWhiteList`, and the firmware has an install
+ blacklist (`pi_config`), so without it APKs may no longer install.
+- `com.xiaomi.mitv.settings`, `com.xiaomi.mitv.systemui`, `com.xiaomi.mitv.providers.settings`: the firmware
+ registers none of the standard `android.settings.*` actions, so these carry the whole settings UI.
+- `mitv.service`, `com.mi.miplay.mitvupnpsink`, `com.xiaomi.miplay`, `com.duokan.airkan.tvbox`: remote and casting.
+- `com.xiaomi.mitv.tvplayer`, `com.mitv.mivideoplayer`, `com.mitv.videoplayer`, `com.mitv.codec.update`: playback.
+
+**The boot ad.** `boot_ad_switch` was unset (`boot_ad=0`, `boot_ad_switch_show=0`). After
+`settings put system boot_ad_switch 0` and a full power cycle the 15-second sponsored boot video was gone and the
+Xiaomi logo (about 10 s) remained; the value survived a reboot. The same key works on other China Xiaomi builds
+([`xiaomi-l43m7-ea-antl0.md`](xiaomi-l43m7-ea-antl0.md)). Undo: `settings delete system boot_ad_switch`.
+
+**The ad SDK.** `com.miui.systemAdSolution`, the system ad SDK of this generation, lives in `/data/app` on this
+build; none of the Xiaomi lists in `examples/` name it. On Android 4.4 `pm block` reaches it
+([`xiaomi-mitv3s-48-hancock-follow-up.md`](xiaomi-mitv3s-48-hancock-follow-up.md)); on this Android 6 build the
+shell cannot disable, hide or block it.
+
+**HOME without the allowlist.** With stock Home removed for user 0 (a route this repo does not use, so it is
+not described here), HOME resolved to a sideloaded third-party launcher by itself, and the Home key reached it
+3 times out of 3 with no accessibility helper. The package-name
+HOME allowlist that later China firmware applies ([`docs/TROUBLESHOOTING.md`](../TROUBLESHOOTING.md)) did not show
+on this Android 6 build. The launcher in this repo still needs Android 8, so this only matters for the fork above.
+
+### Cross-check: Mi TV 4A (MiTV4A, matrix)
+
+From @QiKe-007's comment in #1185: `ro.product.model=MiTV4A`, `ro.product.device=matrix`, MIUI TV `8.8.20.1275`,
+Android 6.0.1, zh-CN, PatchWall the only HOME. The refusals are exactly the same, for system-uid and app-uid
+packages alike; `pm suspend` and `pm block` do not exist, and `adb root` answers `adbd cannot run as root in
+production builds`. So the refusal belongs to the generation, not one build.
+
+- `com.miui.systemAdSolution` is in `/data/app` here too.
+- `com.mitv.screensaver` (`/system/priv-app/TVSmartScreenSaver/`), `com.xiaomi.statistic`
+ (`/system/vendor/app/MiTVStat/`) and `com.xiaomi.devicereport` (`/system/vendor/app/DeviceReport/`) are on
+ read-only partitions. AOSP's dream is already off (`screensaver_enabled=0`); the Mi screensaver runs on its own.
+- **`appops` works from the shell and sticks.** Marketing push notifications go quiet while the push service
+ (and its installer allowlist) stays enabled:
+
+ ```bash
+ "$PY" -I tools/tv.py 'appops set com.xiaomi.mitv.tvpush.tvpushservice POST_NOTIFICATION deny'
+ # check: appops get com.xiaomi.mitv.tvpush.tvpushservice undo: ... POST_NOTIFICATION allow
+ ```
+
+- **adbd takes one client at a time.** `tools/tv.py` timed out (`TcpTimeoutException: Reading from <tv ip>:5555
+ timed out`) while the platform `adb` server held a connection to the same port. `adb kill-server` first.
diff --git a/examples/README.md b/examples/README.md
index c0f2216de..e952d51a3 100644
--- a/examples/README.md
+++ b/examples/README.md
@@ -322,7 +322,7 @@ Notes for models that have no tested list yet live in [`docs/devices/`](../docs/
- [Haier `HaierATVT32DVB`](../docs/devices/haier-haieratvt32dvb.md) (`dupont`, same Haier/CVTE platform as the Durabrand above, Google TV 14 `UKNV.260408.001`): an observed-state note, not a list; the factory stack on Google TV 14, and `com.cvte.tv.fac.menu` named in the don't-launch list.
- [TCL `75c63b`](../docs/devices/tcl-75c63b.md), owner-reported retail model, `Smart TV Pro` / `BeyondTV4`, Android 11, `V8-R51MT05-LF1V652`: launcher-only installation, HOME priorities and component restrictions, correct Live TV player package, restoration and explicit test limits.
- [TCL `55C728`](../docs/devices/tcl-55c728-g05-4k-gb.md), `Smart TV Pro` / `G05` / `G05_4K_GB`, Google TV 11 `TCL/G05_4K_GB/G05:11/AR2101/AR28`: a same-day 23-package set kept as a note, the G05 reboot answer by build (`AR68` puts setupwraith back, the `G05_4K_GB` units do not), the remote keycodes and vendor input URIs, and why this owner kept `com.tcl.suspension` where the US list disables it; a second unit (TCL 65C835, Italy, Wi-Fi) adds the reference launcher on `AR28`, a Wi-Fi network setupwraith did not own, and 17 packages that were already not installed before its cleanup.
-- [Xiaomi Mi TV 4S 75" (MiTV4-ANSM0)](../docs/devices/xiaomi-mitv4-ansm0.md), China, Android 6.0.1 (API 23), firmware `20.3.6.2057`: `pm disable-user` and `pm hide` are refused, so there is no disable list. The launcher fork hides 应用中心, 电视管家, 定时提醒 and 无线投屏; 米家, 云视听小电视, voice, update and the HDMI player stay. Stock home `com.mitv.tvhome` can return on boot.
+- [Xiaomi Mi TV 4S 75" (MiTV4-ANSM0)](../docs/devices/xiaomi-mitv4-ansm0.md), China, Android 6.0.1 (API 23), firmware `20.3.6.2057`: `pm disable-user` and `pm hide` are refused, so there is no disable list. The launcher fork hides 应用中心, 电视管家, 定时提醒 and 无线投屏; 米家, 云视听小电视, voice, update and the HDMI player stay. Stock home `com.mitv.tvhome` can return on boot. A second set (Mi TV 4A 50", build `3390`) and a MiTV4A cross-check show the same refusals, what must stay enabled, the `boot_ad_switch` key and an `appops` mute for the push service.
- [Xiaomi MiTV-MFTR0 "freeguy"](../docs/devices/xiaomi-mitv-mftr0-freeguy.txt), China, Android 14: inputs, Xiaomi settings intents, app discovery.
- [Philips 50PUH8215/96](../docs/devices/philips-50puh8215-96.md) (`TPM191E`, Android TV 11 `RTT2.211108.001/3565`): one-session six-package debloat and stock Home replacement, verified after a reboot; HDMI 1 input selection, owner-reported remote buttons, and Clock screensaver preview. The Android 12 TPM191E list has a different firmware, and this unit has no several-day list yet.
- [Philips 65PUG7406/78](../docs/devices/philips-65pug7406-78.md), Brazil, Android TV 11, `TPM215L_R.105.000.097.000`: HOME handover notes and owner-selected Live TV/Assistant disables; no several-day debloat list.