1

I want to profile an Android application on a physical Android device without using a USB connection from the device to my computer. The device's USB port is being used by a peripheral that is essential to my application.

I'm using the Android Wifi ADB Android Studio plugin and have successfully connected the device to utilise the bridge to Android Studio 3.2.1

When I attempt to begin a new profiling session using the Android Profiler my connected device appears to have "no debuggable processes."

How can I profile my application without a USB connection to my Android device?

Sarkis
  • 303
  • 2
  • 12

2 Answers2

0

You need to enable adb integration, Go to Tools-->Android-->Check Enable ADB Integration

It was a default feature a few versions ago but now it has been disabled by default.

rdj7
  • 1,905
  • 4
  • 18
  • 33
  • Great to hear! I've searched Tools but can't find Android and I can't find Enable ADB Integration searching with the `Find Action` tool. I'm on Android Studio 3.2.1 – Sarkis Nov 09 '18 at 14:55
  • https://i.imgur.com/3O5ofeX.png on Android Studio 3.2.1 I don't have the option. https://stackoverflow.com/a/49625983/7015599 suggests it was removed from Android Studio 3.2 – Sarkis Nov 09 '18 at 15:25
  • Preferences > Build, Execution & Deployment > Debugger Then check or uncheck the box Use libusb backendhttps://stackoverflow.com/questions/47904505/android-studio-3-1-does-not-showing-android-option-under-tools-menu – omair issa Nov 09 '18 at 20:48
  • Thank you but I've attempted that fix already and still no success. This is a lot of comments so I've created another post: https://stackoverflow.com/q/53229325/7015599 – Sarkis Nov 09 '18 at 20:56
0

I've found a solution thanks to Unity's list of Android profilers.

At this time on Android Studio version 3.2.1 ADB and the Android Profiler do not work together over WiFi.

For my case I've found simpleperf to be acceptable, a tool which includes functionality to generate CPU flame graphs. I used run_simpleperf_without_usb_connection.py specifically, as documented in the simpleperf README available here.

Sarkis
  • 303
  • 2
  • 12