ANDROID - Stuck on "Sending to Device"

lorenk

  • Posts: 36
I read through the post about testing on Android (http://community.stencyl.com/index.php/topic,13723.0.html) and followed the available directions while setting things up to test. Things were working great for a couple hours, then things got stuck on the "Sending to Device" phase of testing. I'm using a Nexus 7 running Android 4.2.2

These are the steps I've taken to try and address the problem:
-Unplugged device just in case the computer fell asleep
-Turned Developer Options off & on
-Turned USB Debugging off and on
-Uninstalled and re-installed the USB drivers from ASUS (did this twice and restarted after each time)
-Tried publishing two separate Stencyl games that previously were sent to the device without issue
-Used a file manager on the Nexus to uninstall the apps that were hanging around from the earlier tests.

I can publish to an .apk file and transfer it manually to the Nexus without issue.

Any recommendations on how to address this issue?

« Last Edit: November 29, 2014, 10:26:49 am by Jon »

Hectate

  • *
  • Posts: 4643
You should probably see if the Android Device Bridge is properly detecting your device when it's plugged in. If you go into the workspace folder that hold the APK, there's some nearby folders for the SDK including a tools directory - look for one called "adb.exe". You'll have to run it from a command prompt but if you do it ("adb devices" I think) it'll report if it sees the device.
:
:
Patience is a Virtue,
But Haste is my Life.
Proud member of the League of Idiotic Stencylers; doing things in Stencyl that probably shouldn't be done.

lorenk

  • Posts: 36
From running adb.exe devices, I receive the following:
* daemon started successfully *
List of devices attached
015d49069967f412 offline

I believe it detects a connection but it's not initializing when the game is published. I was looking at the following site http://developer.android.com/tools/help/adb.html and this info stood out to me.

Quote
When you connect a device running Android 4.2.2 or higher to your computer, the system shows a dialog asking whether to accept an RSA key that allows debugging through this computer. This security mechanism protects user devices because it ensures that USB debugging and other adb commands cannot be executed unless you're able to unlock the device and acknowledge the dialog. This requires that you have adb version 1.0.31 (available with SDK Platform-tools r16.0.1 and higher) in order to debug on a device running Android 4.2.2 or higher.

The device was working prior to 4.2.2 being installed. I ran adb.exe version, and it looks like the version Stencyl installs is 1.0.26. Stencyl would need to install 1.0.31 for things to work with Android devices running 4.2.2 I believe.

mguido730

  • Posts: 600
I've also been having this issue with my Nexus 7, I forgot that i had updated it but i'm pretty sure that's the problem as lorenk said because it was fine for me before updating it as well.
Matt Guido (@guidolatry)

Co-Founder/Programmer at The Automatic Gentlemen.

lorenk

  • Posts: 36
To get things temporarily working I did the following:

-Downloaded the latest Android SDK (http://developer.android.com/sdk/index.html)
-Pulled aapt.exe, adb.exe, AdbWinApi.dll, AdbWinUsbApi.dll, and dx.jar out of the platform-tools folder and replaced the files in the platform-tools folder in Stencyl's directory. Not sure if you need to replace all of these files.
-Ran Stencyl and tested a game.
-Accepted the message on the Nexus to allow files from my computer.
-Restarted Stencyl (for some reason Stencyl went from "Sending to Device" to "Compiling" when I got the above message).
-After restart testing began working again.

jihem

  • *
  • Posts: 161
I got the same issue and I solved it with the SDK manager in stencylworks (with some help too).

http://community.stencyl.com/index.php/topic,20771.0.html
while (!success=retry());

Sock Puppet

  • Posts: 9
Replying on this old thread because it is linked to directly from the Stencylpedia article.

I had the problem where it got to "Sending To Device" and then nothing happened. I had both network data and WiFi disabled on my device at the time. I enabled WiFi and tried again, and it worked. It's not a smoking gun pointing at the need to have some kind of network data enabled, but indicates that it *might* be necessary and is worth trying. My device is a Moto G5 Plus.

Beckb

  • Posts: 72
This fixed most of my android testing problems. I found it on an older thread:

"Running Android SDK Manager (Launched from Android Device Manager > Window > Android SDK Manager) and installing everything under the "Tools" folder (including 19.1.0).  This solved everything. Game compiled and launched on phone."

http://community.stencyl.com/index.php?topic=38465.0