How can I change the preferred network type with ADB?
Example: set Use only GSM, use only WCDMA, use only LTE or automatic.
First, choose “Settings” from your “Apps.” Tap on “More” > “Mobile Networks” > “Preferred Network Type.” Here, you can choose between 4G, 3G, or 2G.
This is working for my devices:
adb shell sqlite3 /data/data/com.android.providers.settings/databases/settings.db "update global SET value = 1 WHERE name = 'preferred_network_mode'"
adb shell sqlite3 /data/data/com.android.providers.settings/databases/settings.db "select value FROM secure WHERE name = 'preferred_network_mode'"
adb shell settings put global airplane_mode_on 1
adb shell am broadcast -a android.intent.action.AIRPLANE_MODE --ez state true
sleep 5;
adb shell settings put global airplane_mode_on 0
adb shell am broadcast -a android.intent.action.AIRPLANE_MODE --ez state false
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With