Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remote debug app #62

Open
likezjuisee opened this issue Feb 15, 2017 · 12 comments
Open

remote debug app #62

likezjuisee opened this issue Feb 15, 2017 · 12 comments

Comments

@likezjuisee
Copy link

I came with the problem as the picture below when I used android studio 2.2.3 to debug an app. But the eclipse is ok with the same app. I am confused. Could you give me some advice. Thanks.
cc80d250-f2d2-11e6-99c8-6f1bb16f115d

@sorccu
Copy link
Member

sorccu commented Feb 15, 2017

Check if it works if you use your phone with the regular adb tcpip over wifi.

@likezjuisee
Copy link
Author

My phone is not rooted, so adb tcpip will be a little complicated to me. Could you try to debug like mine?

@sorccu
Copy link
Member

sorccu commented Feb 15, 2017 via email

@likezjuisee
Copy link
Author

I have tried 5 times, the adb tcpip is ok.

@sorccu
Copy link
Member

sorccu commented Feb 15, 2017

When you connect the device via adbkit, is the device also connected locally to the same machine with a usb cable?

@likezjuisee
Copy link
Author

The adbkit runs on the computer which is connected by the phone via usb. And the android studio is another computer, connected the phone by the command adb connect 10.18.131.59:6174

@likezjuisee
Copy link
Author

And the as debug logs as below:

02/15 16:00:24: Launching app
$ adb push I:\project\android-platform_sdk-master\MyApplication2\app\build\outputs\apk\app-debug.apk /data/local/tmp/com.example.administrator.myapplication
$ adb shell pm install -r "/data/local/tmp/com.example.administrator.myapplication"
pkg: /data/local/tmp/com.example.administrator.myapplication
Success

$ adb shell am start -n "com.example.administrator.myapplication/com.example.administrator.myapplication.MainActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -D
Waiting for application to come online: com.example.administrator.myapplication.test | com.example.administrator.myapplication
Waiting for application to come online: com.example.administrator.myapplication.test | com.example.administrator.myapplication
Waiting for application to come online: com.example.administrator.myapplication.test | com.example.administrator.myapplication
Waiting for application to come online: com.example.administrator.myapplication.test | com.example.administrator.myapplication
Waiting for application to come online: com.example.administrator.myapplication.test | com.example.administrator.myapplication
Waiting for application to come online: com.example.administrator.myapplication.test | com.example.administrator.myapplication
Waiting for application to come online: com.example.administrator.myapplication.test | com.example.administrator.myapplication
Waiting for application to come online: com.example.administrator.myapplication.test | com.example.administrator.myapplication

@sorccu
Copy link
Member

sorccu commented Feb 15, 2017

Ok looks like I'll have to run some packet captures later 😞

@likezjuisee
Copy link
Author

Thanks a lot! Waiting for you response.

@englefly
Copy link

englefly commented Feb 17, 2017 via email

@sorccu
Copy link
Member

sorccu commented Feb 17, 2017

I just tried it with a simple hello world app and it was fine. After pressing the "debug app" icon in Android Studio, the "waiting for debugger" appeared on the device for a moment but quickly went away, and the app appeared. I did not experience any disconnections with Android Studio, either.

My computer:

  • OS X 10.12.3
  • Android Studio 2.2.3 with latest SDK
  • adb version: Android Debug Bridge version 1.0.36 Revision 0e9850346394-android

STF host:

  • Arch Linux

Device:

  • Nexus 5X

Seems to work fine. I need more details from you if you want me to look into this. Full details of your computer, the STF host computer, and the device are needed. You may even need to send me the APK file.

@likezjuisee
Copy link
Author

Thanks a lot!
I will try to find the detail of the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants