Starting March 27, 2025, we recommend using android-latest-release
instead of aosp-main
to build and contribute to AOSP. For more information, see Changes to AOSP.
Capture traces
Stay organized with collections
Save and categorize content based on your preferences.
You can capture traces on the
device,
through
Winscope,
or through
Android Debug Bridge (adb)
commands.
In Winscope, you can retrieve the latest traces collected from a device during
the previous session. This feature is especially helpful when facing connection
issues, such as using ADB over Wi-Fi, or when Winscope closes unexpectedly. If
there are no traces from the last session, Winscope displays No valid trace
files found.
Error messages
Winscope shows the following messages during trace collection:
Message |
Description |
No trace targets selected |
No trace checkboxes are selected. |
Errors occurred during tracing:
ERROR: INVALID_LAYER_STACK , please
check your display state (must be on
at start of trace) |
A screen recording was requested, but the display was off at the start
of trace. |
Errors occurred during tracing:
A specific error message received from
adb command, such as Failed to
find valid files for <trace types
requested> |
adb couldn't read the trace files, which typically happens when
adb isn't running as root. |
Errors occurred during tracing:
Tracing time out |
There's a connection issue with the device. |
Errors occurred during tracing:
{inner error} |
This message covers all other errors. |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-08-29 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-29 UTC."],[],[],null,["# Capture traces\n\nYou can capture traces on the\n[device](/docs/core/graphics/winscope/capture/on-device),\nthrough\n[Winscope](/docs/core/graphics/winscope/capture/winscope),\nor through\n[Android Debug Bridge (adb)](/docs/core/graphics/winscope/capture/adb)\ncommands.\n\nIn Winscope, you can retrieve the latest traces collected from a device during\nthe previous session. This feature is especially helpful when facing connection\nissues, such as using ADB over Wi-Fi, or when Winscope closes unexpectedly. If\nthere are no traces from the last session, Winscope displays **No valid trace\nfiles found**.\n\nError messages\n--------------\n\nWinscope shows the following messages during trace collection:\n\n| Message | Description |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------|\n| No trace targets selected | No trace checkboxes are selected. |\n| Errors occurred during tracing: ERROR: `INVALID_LAYER_STACK`, please check your display state (must be on at start of trace) | A screen recording was requested, but the display was off at the start of trace. |\n| Errors occurred during tracing: A specific error message received from adb command, such as Failed to find valid files for *\\\u003ctrace types requested\\\u003e* | adb couldn't read the trace files, which typically happens when adb isn't running as root. |\n| Errors occurred during tracing: *Tracing time out* | There's a connection issue with the device. |\n| Errors occurred during tracing: *{inner error}* | This message covers all other errors. |"]]