dudave
Android Fan
Profile
Posts: 111
Reg: Mar 23, 2011
Israel, Netanya
1,110
01/15/13 02:28 AM (13 years ago)

Testing my app on my android device

hi, from what i understood there is an option to test the app/project on an actual android device by plugging the device to the computer and chosing it via eclipse, i tried to find a way to set up the device in the AVD manager but couldn't find a way to do it, what am i missing? Thanks David
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
01/15/13 03:03 AM (13 years ago)
Umm, as far as I know, you're not missing anything. When I have my device connected via USB to my computer, my device comes up as a choice. AVD are "Virtual Devices", not actual devices, so AVD Manager shouldn't play a part in this process. Have you launched your app with your device connected? If it didn't appear as a choice, you may want to see if any drivers are required... I'm using my Mac; so things just 'happened'. I'm not sure if any configuration is needed on the windows side. Hope it works out, but try to see if it works, and let us know how it turned out. Cheers! -- Smug
 
RobinvanKrieken
Aspiring developer
Profile
Posts: 50
Reg: Dec 20, 2012
Amsterdam
6,500
like
01/15/13 03:11 AM (13 years ago)
Hi David, I haven't heard of this possibility yet. But then agin, I am an absolute newbie here. If it exists I'd like to know about it. But the way I am doing it now works fine too. I don't know if you've used this method yet? >> Clean and refresh your project in Eclipse and run it through your emu. Now go to the bin folder of your project and send the apk file to your Android (I use Dropbox for this) and click on it to install your app. Robin
 
dudave
Android Fan
Profile
Posts: 111
Reg: Mar 23, 2011
Israel, Netanya
1,110
like
01/15/13 03:29 AM (13 years ago)
Thanks, indeed my device doesn't appear were it's suppose to, i don't know why as my computer do recognize the device. i tried restarting both the device, eclipse and my pc, it didn't help. i also used the clean + refresh. Robin, i want to try your sugestion but i lost you on the last part, i went to my bin folder, found the APK file, now here i'm stuck, i don't know how to send it to my android. Thanks again David
 
dudave
Android Fan
Profile
Posts: 111
Reg: Mar 23, 2011
Israel, Netanya
1,110
like
01/15/13 03:40 AM (13 years ago)
figured that out, i downloaded dropbox and it worked, thanks a lot!! David
 
RobinvanKrieken
Aspiring developer
Profile
Posts: 50
Reg: Dec 20, 2012
Amsterdam
6,500
like
01/15/13 03:50 AM (13 years ago)
You're welcome. Don't forget that sometimes you will need to reinstall your apk after making certain changes to your project (like adding images - not img urls). Cheers, Robin
 
Paul Rogers
Android Fan
Profile
Posts: 2524
Reg: May 30, 2011
UK
35,740
like
01/15/13 06:04 AM (13 years ago)
@dudave, Your pc detects your phone, that's good. Connect phone to pc with usb cable, then in your phone - depending on your version it'll be 'Settings > Developer options' or 'Menu > Settings > Development' - Select 'USB Debugging'. Then in Eclipse next to the 'run' button there's a drop down arrow: https://dl.dropbox.com/u/56760890/Untitled-22.png Select 'Run Configurations' and select the 'Target' tab: https://dl.dropbox.com/u/56760890/Untitled-23.png Select 'Launch on all compatible devices/AVD's' > 'Active Devices' Hit apply and hit run. https://dl.dropbox.com/u/56760890/Untitled-24.png
 
RobinvanKrieken
Aspiring developer
Profile
Posts: 50
Reg: Dec 20, 2012
Amsterdam
6,500
like
01/15/13 06:09 AM (13 years ago)
@raveyd, Thx for that! Learning, learning! Robin
 
Paul Rogers
Android Fan
Profile
Posts: 2524
Reg: May 30, 2011
UK
35,740
like
01/15/13 06:17 AM (13 years ago)
@RobinvanKrieken - it's a never ending learning curve! As ever with Android there's a caveat or two. Some older devices may need additional drivers as @Smug pointed out. The usual place to find them is on the device manufacturers faq's or forums. With most phones though, there shouldn't be a problem.
 
ATRAIN53
Code is Art
Profile
Posts: 1755
Reg: Nov 17, 2011
Chicago
26,450
like
01/15/13 08:02 AM (13 years ago)
The easiest way is to just build the .apk Upload that .apk to your PUBLIC folder on dropbox- (or any url you want to use) Copy that link and then email that link to yourself. Open that email, click the link and as long as you have allowed your device to load NON MARKET APLICATIONS It should download and install. This is one area Android is much easier than iOS! Take advanatage of it!
 
Paul Rogers
Android Fan
Profile
Posts: 2524
Reg: May 30, 2011
UK
35,740
like
01/15/13 08:39 AM (13 years ago)
@ATRAIN53, that IS easy, but it's not a running emulator.
 
RobinvanKrieken
Aspiring developer
Profile
Posts: 50
Reg: Dec 20, 2012
Amsterdam
6,500
like
01/15/13 09:41 AM (13 years ago)
@ATRAIN53, I do the same but don't use email. I just open dropbox on my android and click on the .apk. That's enough for install. But I agree with @raveyd, it's not an emu. I can only check my app on my one device. For a simulation of other devices I still need the emulator AVD. And I don't trust it cuz it doesn't show changes that ARE being shownn on my Android. Is there way to "fix" your emulator (other than deleting it and creating a complete new one)? Robin
 
ATRAIN53
Code is Art
Profile
Posts: 1755
Reg: Nov 17, 2011
Chicago
26,450
like
01/15/13 10:02 AM (13 years ago)
nope, tis not - It just sounded like the poster wanted to get the app on his device. The only time I connect my Android device to my computer is to use the Dalvik Debug tools- You guys might find this useful: http://developer.android.com/tools/debugging/ddms.html Any other time I connect up a droid device - it always wants to install the native software and driver. I don't need/want all that extra HTC 'active sync' or some lame "LG Phone manager' slowing down my already bloated windows os. I lived thru that whole Blackberry Desktop Manager era - I'd rather get a root canal than install that bloatware again!
 
RobinvanKrieken
Aspiring developer
Profile
Posts: 50
Reg: Dec 20, 2012
Amsterdam
6,500
like
01/15/13 10:18 AM (13 years ago)
@ATRAIN53, Got it ;) Thx for the liknk. Robin
 
GoNorthWest
buzztouch Evangelist
Profile
Posts: 8197
Reg: Jun 24, 2011
Oro Valley, AZ
1,000,000
like
01/15/13 11:58 AM (13 years ago)
Good stuff in this thread! It can be challenging to get Eclipse to recognize your device. I, too, have found that if Windows (or Mac or Linux or whatever) recognizes your device, then Eclipse should as well. There is a view you can add to Eclipse that shows devices it sees. That's helpful to have for a quick look at what's going on. I like to debug on a live device as well...I often run against my Nexus while watching LogCat output! Mark
 
dudave
Android Fan
Profile
Posts: 111
Reg: Mar 23, 2011
Israel, Netanya
1,110
like
01/19/13 01:21 AM (13 years ago)
now it's interesting, i try to test my app both on my device and the emulator, i'v been working on a text/html page for a few days, every time i test it on the device it works fine but on the emulator i get a blank page, sometimes it pops an error that says that the content of the page hasn't been downloaded yet and sometimes it doesn't say anything. i tried many times with all kind of stuff, i cleaned, refeshed, re-dowloaded the project, i updated manually the config file and what not, i'm out of ideas! Thanks
 
RobinvanKrieken
Aspiring developer
Profile
Posts: 50
Reg: Dec 20, 2012
Amsterdam
6,500
like
01/19/13 04:18 AM (13 years ago)
@dudave, I don't know if you're iOs or Android... If Android: did you delete existing emulator and create a new one? If not: 1. in Eclipse delete your emu. 2. Restart Eclipse. 3. Make sure you import a new version of your project. 4. Create new emulator of choise. 5. Run your app in the emu. This worked for me. Robin
 
dudave
Android Fan
Profile
Posts: 111
Reg: Mar 23, 2011
Israel, Netanya
1,110
like
01/19/13 08:38 AM (13 years ago)
did that now, but it didn't solved the problem, still getting the "datat not downloaded" error on the emulator and then a blank page
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.