Page 1 of 1

Launching GPS Point in Android Google Earth from CSPro

Posted: August 20th, 2014, 2:54 pm
by KASTELIC
Dear CSPro Android Beta Users,

I'm wondering if anyone knows if it is possible to pass a parameter to Google Earth (or Google Maps) when launched it from your CSPro Android CAPI application.

Obviously launching Google Earth is pretty easy by using the execsystem function,

execsystem("app:com.google.earth");.

But what I am looking for is for it to show my current location or a set of gps coordinates, or address, of my specification.

Any experiences?

Best,

Jon

Re: Launching GPS Point in Android Google Earth from CSPro

Posted: August 20th, 2014, 10:03 pm
by pierre
Hey Jon,
Does this work? Never tried it but if execsys uses the same android launcher then it might work.

execsystem("geo:7.3419443,134.4791667");
Don't forget to make google.earth your default map viewer.

Laters,
Pierre

Re: Launching GPS Point in Android Google Earth from CSPro

Posted: August 21st, 2014, 1:09 pm
by KASTELIC
Thanks Pierre.

Unfortunately the standard geo execution does not work through the cspro execsystem. "app:", "call:", "browse:", "camera", and "view" all work, but "geo" does not. Not sure if its just not something that CSPro allows or if I am missing something.

Has anyone else been about to make this work?

Jon

Re: Launching GPS Point in Android Google Earth from CSPro

Posted: August 21st, 2014, 2:34 pm
by Gregory Martin
Interesting. I didn't implement such a thing for execsystem. Would that be useful, using it like Pierre's suggestion, with the latitude and longitude? If so, I'll add it in.

Re: Launching GPS Point in Android Google Earth from CSPro

Posted: August 21st, 2014, 3:30 pm
by KASTELIC
Hi Greg,

I think this would be a great addition to the CSPro Andriod!

Having the ability to map coordinates on google maps or google earth could be very helpful in navigating to sampled locations (households, health facilities, markets, etc.).

If its possible to list out multiple locations and label them that would be ideal.

For example, execsystem(maketext("geo: %s %d %d %s %d %d), [location label #1], [lat], [long], [location label #2], [lat], [long]); or the like.

Jon

Re: Launching GPS Point in Android Google Earth from CSPro

Posted: September 26th, 2014, 9:29 pm
by Gregory Martin
For the current release, we're just going to support one point. You'll make a call like this:
execsystem("gps:38.8977,-77.0365,White House");
In the future we'll look into displaying more than one point at a time. I can see how this would be useful for displaying to interviewers where the sampled households are.

Re: Launching GPS Point in Android Google Earth from CSPro

Posted: September 29th, 2014, 4:59 am
by KASTELIC
Very nice! Thanks!

Re: Launching GPS Point in Android Google Earth from CSPro

Posted: September 29th, 2014, 4:37 pm
by jfigueroa
It would be very useful, Mr. Gregory Martin.
Thanks.