I want to make a code to enable the developer mode and set a parameter on this ( the one to always allow roaming detection so we can switch to a better wifi if found).
I saw some apps that can launch developer mode, but nothing is opening it AND changing some parameters. I can't ask to users to set this parameter themselves, so how can I make this myself?
I saw also that we can do this by shell :
adb shell am start -n com.android.settings/.DevelopmentSettings
But afterwards i don't know how to set automatically a parameter.
As I made my own app, I could launch developer mode and this param on the start of my app.
Did anyone made this before inside of an app? How can I call DevelopmentSettings activity inside my app and edit some of its parameters?
Thanks
EDIT
I can eventually root all my phones and set my app inside system folder, It can be complicated but we could manage it. If I does, How can I access to the parameters of developer mode programatically?
You can use following code but you need root access for this.
.Settings.Secure.putInt(getActivity().getContentResolver(),Settings.Secure.ADB_ENABLED, 1);
For More information Check this link : How to access device settings programmatically?
Thanks
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