Extreme Thinking
adb shell

2019-12-10


這邊紀錄一下 adb shell … 改天再增加其他的

關閉 SIM 卡 (開飛航)

settings put global airplane_mode_on 1
am broadcast -a android.intent.action.AIRPLANE_MODE --ez state true

開啟 SIM 卡 (關飛航)

settings put global airplane_mode_on 0
am broadcast -a android.intent.action.AIRPLANE_MODE --ez state false

WIFI on-off (我試沒反應)

adb shell am broadcast -a android.intent.action.WIFI_ON 
adb shell am broadcast -a android.intent.action.WIFI_OFF

adb shell am broadcast -a android.intent.action.CONNECT_TO_WIFI -e ssid {wifi_ssid} -e password {pwd}