A tip is sought for an optimal solution.
In this use case, the app should play a local sound file that may run for more than 20 minutes.
It must be ensured that playback continues even if the app would otherwise go into standby due to energy settings.
It’s known that this function can be controlled using “PhoneWakeState” with “KeepAlive” in Activity_Resume and “ReleaseKeepAlive" in Activity_Pause.
“PartialLock” and “ReleasePartialLock” are also available.
Does it make a difference to start "KeepAlive" in `Activity_Resume` versus immediately before starting the MediaPlayer?
However, due to limited experience in this area, guidance on the best approach is needed to keep the app’s energy consumption within reasonable limits.
Which approach is most effective for ensuring continuous playback while balancing the app’s energy consumption?
In this use case, the app should play a local sound file that may run for more than 20 minutes.
It must be ensured that playback continues even if the app would otherwise go into standby due to energy settings.
It’s known that this function can be controlled using “PhoneWakeState” with “KeepAlive” in Activity_Resume and “ReleaseKeepAlive" in Activity_Pause.
“PartialLock” and “ReleasePartialLock” are also available.
Does it make a difference to start "KeepAlive" in `Activity_Resume` versus immediately before starting the MediaPlayer?
However, due to limited experience in this area, guidance on the best approach is needed to keep the app’s energy consumption within reasonable limits.
Which approach is most effective for ensuring continuous playback while balancing the app’s energy consumption?