Feature: Intent-based Automation for PowerPlay Sample#2341
Open
madebymozart wants to merge 3 commits intomainfrom
Open
Feature: Intent-based Automation for PowerPlay Sample#2341madebymozart wants to merge 3 commits intomainfrom
madebymozart wants to merge 3 commits intomainfrom
Conversation
Collaborator
|
Q: is the playback loop by default? |
Collaborator
Author
|
@flamme yes, we can maybe also add a loop button to the player controls to control this better. |
flamme
reviewed
Jan 30, 2026
| val durationMs = IntentBasedTestSupport.getDurationMs(extras) | ||
| val useMMap = IntentBasedTestSupport.getMMapEnabled(extras, player.isMMapEnabled()) | ||
| val bufferFrames = IntentBasedTestSupport.getBufferFrames(extras) | ||
| val toggleOffload = IntentBasedTestSupport.isToggleOffloadRequested(extras) |
Collaborator
There was a problem hiding this comment.
Q: shouldn't offload or not be decided by the performance mode? Why it is needed to have another toggle for offload?
Collaborator
Author
There was a problem hiding this comment.
Removed the toggle based intents
flamme
approved these changes
Feb 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description: Intent-based Automation and Stress-Testing for PowerPlay
Summary
This PR implements a robust command-line interface for the PowerPlay sample app via Android Intents. This enables full control of the audio engine via
adb, facilitating automated power profiling, stress testing, and validation of PCM Offload behavior without manual UI interaction.Changes
MainActivity.javato trigger engine actions and configuration changes.none,lowlat,powersave, andoffloadvia commands.toggle_offloadmode to test system stability during rapid resource transitions.duration_msfor self-terminating tests and abackgroundflag to test system behavior during display-off/doze transitions.POWERPLAY_STATUSlogcat outputs for easy parsing by external automation scripts.Supported ADB Parameters
commandplay,pause,stopperf_modenone,lowlat,powersave,offloadsong_indexvolumebackgroundduration_mstoggle_offloadHow to Test
You can verify the automation by running the following command to start a timed, background offload session:
adb shell am start -n com.google.oboe.samples.powerplay/.MainActivity \ --es command play \ --es perf_mode offload \ --ez background true \ --ei duration_ms 10000