diff --git a/Tools/android_run.py b/Tools/android_run.py index b2f7cd8203..96b2aaaae4 100644 --- a/Tools/android_run.py +++ b/Tools/android_run.py @@ -60,6 +60,9 @@ def build_and_install(device): def start(device, app_args): """Force-stops the app and starts it with app_args (a list of options).""" adb(["shell", "am force-stop " + PACKAGE], device) + # Some devices default every log tag to silent (persist.log.tag=S), which drops all of ours before it + # reaches logcat. This lets ours through, until the next reboot. + adb(["shell", "setprop log.tag.PPSSPP V"], device) command = "am start -n %s/.PpssppActivity" % PACKAGE if app_args: # The shell on the device parses this once more, so quote the whole thing. diff --git a/docs/android-device-testing.md b/docs/android-device-testing.md index 80ac1577ca..0a51f84a5a 100644 --- a/docs/android-device-testing.md +++ b/docs/android-device-testing.md @@ -88,7 +88,8 @@ away within seconds, which reads as "logging stopped" rather than "logging was l python Tools/android_run.py --log --start-screen=firmware # and follow the app's log It force-stops the app first, since options are only read at startup, and passes them in the -`org.ppsspp.ppsspp.Args` intent extra. The `--start-screen` names are in `NativeInit()` in `UI/NativeApp.cpp`. +`org.ppsspp.ppsspp.Args` intent extra. It also sets `log.tag.PPSSPP` to `V`: some devices default every +tag to silent (`persist.log.tag` is `S`), and then logcat busily shows other apps but never a line of ours. The `--start-screen` names are in `NativeInit()` in `UI/NativeApp.cpp`. ## Running the C++ unit tests on a device