I need to open USB Mass Storage Activity from my application.
Is there any Intent
to do this?
something like
startActivity(new Intent(Settings.ACTION_APPLICATION_DEVELOPMENT_SETTINGS))
I need to open USB Mass Storage Activity from my application.
Is there any Intent
to do this?
something like
startActivity(new Intent(Settings.ACTION_APPLICATION_DEVELOPMENT_SETTINGS))
You can try to use following:
su -c setprop sys.usb.config <command>
Full list of can be found by this one command:
cat init.usb.rc
Function to be able to run command from app:
public void RunAsRoot(String[] cmds){
Process p = Runtime.getRuntime().exec("su");
DataOutputStream os = new DataOutputStream(p.getOutputStream());
for (String tmpCmd : cmds) {
os.writeBytes(tmpCmd+"\n");
}
os.writeBytes("exit\n");
os.flush();
}
© 2022 - 2024 — McMap. All rights reserved.