Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - flashman

#1
This methods seems to do nothing. I tried this, but even no success:


Intent i = new Intent("com.oruxmaps.VIEW_MAP_ONLINE");
        double [] targetLat = {53.12,53.38};
        double [] targetLon = {13.12,13.22};
        String [] targetNames = {"START","ZIEL"};
        i.putExtra("targetLat", targetLat);
        i.putExtra("targetLon", targetLon);
        i.putExtra("targetName", targetNames);
        i.putExtra("navigatetoindex", 1);
        startActivity(i);


I thought this might be the way to activate navigation to waypoint "Ziel", which should have index 1, while "Start" has index zero.


int[] targetType = i.getIntArrayExtra("targetType");//waypoint type

Should give me a array of integers to do what?


int navigatetoindex = i.getIntExtra("navigatetoindex", -1);//waypoint index from provided waypoints to start navigation mode

Since its an "get" method, it should return an index? What to do with?



I am very sorry for the maybe stupid questions, but there is no reference to look at in this special case. :-)
#2
Great. Will try it out. Thanks for the help.
#3
Thanks a lot, works perfect. But this is the same snipped, as described on the last page of the manual.

So there are some questions left - Can the API do more?



Using the code provided, I can create waypoints or trackpoints. If I call my app twice, Orux shows points as duplicates.

Is there an ID-key management, which avoid duplicates and let me control points already created?



For example:



...

i.putExtra("targetName", targetNames);

i.putExtra("targetId",<unique_ID>);

...



And since my <unique_ID> will we alway the same per dataset, Orux won`t create it again.



So with this idea, it should be possible to remove or hide created points?

And finally: How can I start a navigation to a point just created?



...

i.setAsTarget(<unique_ID>);

startActivity(i);

...



Hope you can help, since I am sure, the Orux api is much bigger and powerful.



Thanks so much,

Andreas
#4
Hi there.



I am looking for some kind of API of OruxMaps, which gives me the possibility, to create a waypoint in an own app, send it directly to Orux (which is already running or will be started) and make it the default "Go To" destination. All this should be as fast as possible. So in best case, the private app is open, I press a button, the app calculates a waypoint, sends it to Orux, Orux becomes active app and navigates / points (direct line) to the new waypoint, without any interactions via touchscreen and Orux so far.



Would be so nice, if this is possible. Any help warmly welcome.



Kind regards,

Andrew