basti564 / Oculess

Removes account requirements and telemetry from Oculus Quest devices
The Unlicense
1.81k stars 76 forks source link

[Feature Request] Disable noise warning #70

Open crutchcorn opened 1 year ago

crutchcorn commented 1 year ago

There seems to be a feature that has the Quest 2 disable the ability to turn up the volume without confirming it in the Quest app.

The problem is that I've removed the account login on my quest and can now no longer turn up the volume. It would be great to disable this "feature" if at all possible. (even with ADB)

crutchcorn commented 1 year ago

This is actually possible using:

import android.provider.Settings

// ...

Settings.Global.putInt(contentResolver,
    "audio_safe_volume_state",
2);

And then rebooting the device after this code is ran.

The problem is that it requires:

<uses-permission android:name="android.permission.WRITE_SECURE_SETTINGS" tools:ignore="ProtectedPermissions" />

In AndroidManifest.xml and the command:

adb shell pm grant com.orgname.packagename android.permission.WRITE_SECURE_SETTINGS

To be ran via ADB.

I'd be happy to contribute this feature and documentation on how others can use it if you'd like, @basti564, but I also understand if you mark this out-of-scope

basti564 commented 1 year ago

I'll consider it, but considering you can already enable it with just adb I don't see why you would want to first grant Oculess write secure settings permission. adb shell settings put global audio_safe_volume_state 2

crutchcorn commented 1 year ago

I, for some reason, remember that command not working for me, but I could be wrong 😅