Skip to content

Instantly share code, notes, and snippets.

@laramartin
Created January 21, 2018 18:21
Show Gist options
  • Save laramartin/7ce2cb93126290652425cc921b4aa34e to your computer and use it in GitHub Desktop.
Save laramartin/7ce2cb93126290652425cc921b4aa34e to your computer and use it in GitHub Desktop.
function start_clean_status_bar {
# Start demo mode
adb shell settings put global sysui_demo_allowed 1
# Display time 12:00
adb shell am broadcast -a com.android.systemui.demo -e command clock -e hhmm 1200
# Display full mobile data without type
adb shell am broadcast -a com.android.systemui.demo -e command network -e mobile show -e level 4 -e datatype false
adb shell am broadcast -a com.android.systemui.demo -e command network -e wifi show -e level 4 -e fully true
# Hide notifications
adb shell am broadcast -a com.android.systemui.demo -e command notifications -e visible false
# Show full battery but not in charging state
adb shell am broadcast -a com.android.systemui.demo -e command battery -e plugged false -e level 100
}
function stop_clean_status_bar {
adb shell am broadcast -a com.android.systemui.demo -e command exit
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment