| Author |
Message |
wannaberunner Freshman

Joined: 03 Mar 2008 Posts: 3
|
Posted: Tue Mar 04, 2008 10:44 am Post subject: |
|
|
Hi Will,
what I did is that I "pulled" the properties file from the /data/misc/location/gps to my computer and then I "pushed" it to /data/misc/location/test1.
Before that, during booting the emulator was saying there was just gps LocationProvider and after I put properties file, it started recognizing new LocationProvider, test1.
It seems to me that the thing which initializes LocationProviders actually looks for a property file in that location and if it finds it, it will name the provider like the directory is called. But, this is just my hunch, and only android team, or a decompiler can tell the truth.
HTH,
Wannabe |
|
| Back to top |
|
 |
|
|
 |
amos Once Poster

Joined: 04 Mar 2008 Posts: 1
|
Posted: Tue Mar 04, 2008 11:31 am Post subject: |
|
|
| wmellon wrote: | wannabe,
Could you be please be more specific about how you "copied the properties file from the default Gps provider?" I'm not sure what this means, or perhaps more importantly, why it worked.
--Will |
Hi wmellon,
The google android website has information on Location Services and their usage, it also explains how to create mock location providers, which is what this very useful (thnx jeremain!) does for us automatically. Check out the details at http://code.google.com/android/toolbox/apis/lbs.html
It doesn't mention that a properties file is required - so many thanks to wannabe for finding out the problem and saving us a whole lot of trouble.
Copying the properties file solved the problem for me, although I had to restart the emulator for it to take effect.
To browse the android phone's file system, you need to run "adb shell" which starts a unix shell of the phone's file system. copying files from your computer's file system to the phone's file system and vice versa is done using "adb push" and "adb pull" respectively.
I assume you're developing with Eclipse, so you can use the DDMS perspective, which has a graphical file browser for the phone and lets you pull and push files. You can explore the phone's file system conveniently from there.
Good luck! |
|
| Back to top |
|
 |
wmellon Freshman

Joined: 03 Mar 2008 Posts: 3 Location: Rochester, NY
|
Posted: Fri Mar 07, 2008 7:08 am Post subject: |
|
|
| wannaberunner; amos, I just wanted to thank you both again for your timely and helpful replies. Works great now! |
|
| Back to top |
|
 |
zeeshan Experienced Developer

Joined: 03 Mar 2008 Posts: 68
|
Posted: Wed Mar 12, 2008 2:09 pm Post subject: Its a ver good tutorial |
|
|
| what is the purpose of Looper here? Looper.prepare() |
|
| Back to top |
|
 |
plusminus Site Admin


Joined: 14 Nov 2007 Posts: 2660 Location: College Park, MD
|
Posted: Wed Mar 12, 2008 4:35 pm Post subject: |
|
|
Hello zeeshan,
I'm not sure (long ago since I had that)...
Its somehow is a problem with handling with views inside a Thread... and not using a handler.
Regards,
plusminus _________________
Download my apps  Please remember, that this board is give & take 
| Android Development Community / Tutorials |
|
| Back to top |
|
 |
zeeshan Experienced Developer

Joined: 03 Mar 2008 Posts: 68
|
Posted: Thu Mar 13, 2008 5:32 am Post subject: |
|
|
what i understand if i am not using handler then i must have to use looper ?
what actually looper does? |
|
| Back to top |
|
 |
|
|
 |
nkho Freshman

Joined: 29 Apr 2008 Posts: 6
|
Posted: Tue May 06, 2008 6:08 am Post subject: |
|
|
Hi Wannabe,
I am also having the same problem. but i tried to follow your way, however i keep on pulling the file from the /data/misc/location/gps to my computer and it keeps prompt me error saying that copying of remote directory not supported (yet). Or maybe can you write the command how you actually pull the file from device?
Thanks
Regards |
|
| Back to top |
|
 |
nkho Freshman

Joined: 29 Apr 2008 Posts: 6
|
Posted: Tue May 06, 2008 10:03 am Post subject: |
|
|
Hi Wannabe,
Thanks Wannabe. It works
Regards |
|
| Back to top |
|
 |
wouter88 Freshman

Joined: 22 Mar 2009 Posts: 2 Location: Overijse
|
Posted: Sun Mar 22, 2009 4:39 pm Post subject: |
|
|
Hey,
Can you update this project to the latest SDK 1.1 please!
I got a lot of errors and missing classes when I want to create this project!
Thank you |
|
| Back to top |
|
 |
|