Skip to content

Instantly share code, notes, and snippets.

@DavidRayner
Last active January 18, 2025 02:46
Show Gist options
  • Save DavidRayner/e66e4ef40da2c636fb95faa7dde59920 to your computer and use it in GitHub Desktop.
Save DavidRayner/e66e4ef40da2c636fb95faa7dde59920 to your computer and use it in GitHub Desktop.
Wanbo T2 apply custom settings on boot
# Connect to device using adb
adb connect <@IP>
# Start su shell (works out of the box - no need to root device)
adb shell
su
# We need to remount the system file-system in order to modify the start-up script
mount -o remount,rw /system
# Backup the original script
cp /system/bin/init_preinstallapk.sh /system/bin/init_preinstallapk.sh.bak
# Use any of the 'echo' lines below to modify the start-up script for your needs
# This line will set background process limit to 1
echo "service call activity 51 i32 1" >> /system/bin/init_preinstallapk.sh
# This line will make device switch to HDMI after boot
echo "/system/bin/monkey -p com.mstar.tv.tvplayer.ui 1" >> /system/bin/init_preinstallapk.sh
# This line will make device run at 720p
echo "wm size 1280x720" >> /system/bin/init_preinstallapk.sh
# Reboot device
reboot
@DavidRayner
Copy link
Author

Source for background process limit: flode/SetAndroidProcessLimit#5

@panoriega
Copy link

Thanks! the projector is working better after changing the background process limit.
I came here because of the HDMI switch on boot, and the performance is really better now!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment