Page 2 of 3

Re: Landmark Open URL Function Missing !!!

Posted: Thu May 05, 2016 7:33 pm
by Yemble
Ok, I have proved my theory with a single landmark, by editing the URL to reference a GPX route file within the /mnt/sdcard/GPX_Routes/ folder. This route displayed correctly in AQ v2 on the phone, unlike before.

So now, all I have do is edit the other 4000+ landmarks :-O

Still don't know why it worked Ok in the previous AQ version referencing /ext/extSdCard/GPX_Routes on exactly the same phone and OS?

Re: Landmark Open URL Function Missing !!!

Posted: Fri May 06, 2016 8:26 am
by Psyberia-Support
Hi again,
Honestly I don't know why it doesn't work anymore, I've not changed anything concerning the file management (list/read/write). Maybe, it has something to do with the Android 6 permissions (don't know on what versions are based your CM) which are now enforced on the new version...
However if you can't see your folders with a regular file explorer, don't expect AlpineQuest to see them too, I guess all apps use the regular way of listing and reading files and folders, which is provided by the Android system...
Here are few ideas:
- After failing to open a file from the app, try to make an error report (main app menu -> More -> Report errors) so I can check if there is any info. You can also try to check/send me your android logs to get more info on underlying progs (like the filesystem logs);
- Don't know if it's possible on Android, but on Linux you can create hard links instead of symlinks, creating "real" files and folders entries (and not just links);
- If all your URL to export are in a GPX file, it's very to update all of them with a simple text editor having a "Find and replace" tool (I use gEdit for that). Just search for "href="/mnt/..." and replace it with your updated version. It will replace all occurrences.
Hope it helps.

After the new update is released, I'll try to make a symling and check what happens on my devices...

Re: Landmark Open URL Function Missing !!!

Posted: Fri May 06, 2016 9:15 am
by Yemble
Actually, before I embark on editing the URLs within all of my route landmarks, I would like to ask you to clarify a few points if I may…

Although this is not a critical point, it would be nice to retain my GPX route repository on my microSD card, rather than the internal storage, due to the fairly tight capacity requirements of my S3 phone. At the same time, I wish to maintain conformity of the route URLs across all my devices, so that I am not having to maintain device specific repositories.

To do this on Marshmallow, I need the landmark URLs to be able to reference a relative file path rather than an absolute file path. This is because in Marshmallow each device has a different physical path to its external SD storage. In previous Android versions, the /mnt/extSdCard symbolic link performed this function, but Marshmallow appears to have taken this away… thanks Google! So, I need an alternative, possibly a variable that AQ understands that maps through to one of the standard AQ folders, eg. …/landmarks/ or …/routes/. Does such a variable exist that could be used within a landmark URL and be properly parsed, dynamically, by AQ? I’m thinking that this might look something like: file://%AQ_ROUTE_PATH%/GPX_Routes/0000/0001.gpx

If not, could this relative pathing be implemented? I don't think that there is any point in trying to fight against changes in the Android 6.x OS, as things are only likely to get worse :shock:

Also, during the course of investigating why this Open URL feature was not working on my phone, I noted that the GPX route files are being imported and converted into LDK files within the …/landmarks/imported landmarks/ folder, effectively (potentially) doubling the size of my routes repository. This seems rather inefficient to me, so I am wondering whether I can bypass this conversion altogether by storing all of my route files in LDK format, rather than GPX format? Unfortunately, LDK appears to be a binary format, rather than text, so I would need some utility to convert these 4000+ GPX files into LDX under batch control, preferably in Windows CLI. Is there such a tool and if so what is the CLI syntax for converting a single GPX file into an LDX file (I can script the processing of multiple files in multiple sub-folders myself)? It is obviously impractical for me to open 4000+ route files individually within AQ in order to get them converted to LDK within the …/landmarks/imported landmarks/ folder.

Do you know if MAP2MAPC can do this landmark conversion? I think that I have used this in the past to convert maps into AQM format.

Finally, assuming that this conversion is possible, would the Open URL function recognise and open a LDK file in the same way that it opens a GPX file?

Re: Landmark Open URL Function Missing !!!

Posted: Mon May 09, 2016 12:42 pm
by Psyberia-Support
Hi again,
I've released version 2.0.1 with something for you.
You can now start the URL with either "file://./" or just "./" to specify the application folder.
So for your routes, you can for example use the URL "./landmarks/GPX_Routes/0000/0001.gpx" on all your devices.

Also, as you've noticed, GPX file are now imported by the application (ie automatically converted to a .ldk file) as it's not possible to directly read or write GPX files with 2.x versions (you must now import/export those files).
Imported files are saved in the "Imported landmarks" sub-folder, and if you import the same GPX file again the application (version 2.0.1) will ask you if you want to re-use the existing imported file so you don't get multiple copies.

I think that the best (and easier) solution for you is just to keep on using your GPX files (as the import is done transparently), and once in a while clean the "Imported landmarks" folder.

Re: Landmark Open URL Function Missing !!!

Posted: Mon May 09, 2016 7:11 pm
by Yemble
That's great, I can certainly work with that, thank you.

You never answered my question about GPX to LDK file conversion. I noticed a reference to GPSBable in the landmark details, so am I correct in assuming that it is this that is used beneath the covers? Has this conversion been exposed to the GPSBable CLI?

One worrying thing I noticed with AQ 2.01 is that I no longer seem to be able to select a displayed route (imported from GPX) in order to follow it or undisplay it. This was working in the previous v2 beta version. Double tap, single tap or long press on a route waypoint no longer have any effect.

Re: Landmark Open URL Function Missing !!!

Posted: Mon May 09, 2016 8:30 pm
by Psyberia-Support
You won't be able to convert internal files used by the application with another application (including GPSBabel). Those files have been made to meet the particular requirements of the app, and are not intended or made to be widely used. Someone asked me for the specifications, which I made available here, but I don't plan to contact anyone to ask for the support those files in another app...

Concerning your selection problem, nothing changed in this version compared to the beta one (it still is a single tap on displayed items). However it seems that there is something wrong with the tap on your device, since you also have problem to use (single tap) the re-lock GPS button... Do you have a protective screen or something like that on your device? Have you noticed tap issues with other apps?

Re: Landmark Open URL Function Missing !!!

Posted: Wed May 11, 2016 11:36 am
by Yemble
I have been running AQ for several years on the same devices on a variety of Android versions. The ONLY thing that has changed recently is AQ, nothing else. v2.0.1.r2926 did work correctly with regard to both displaying routes via URL and then subsequently selecting them via a click on one of the waypoints. All variants of taps work on all three devices and have done for years.

It is this latter, selection, function that is now not working on v2.01 on my CM12.1 NotePro tablet - the routes are displayed, but are effectively dead on the screen. I am not in a position to test it properly on my two S3 phones yet because I have not yet found the time to edit the URL paths to be "relative" to the AQ app folder on the microSD drive. There is definitely an issue here, but it may be due to multiple imports of the same GPX file? Not sure, but if the route selection code has really not changed since v2.0.1.r2926, where route selection definitely did work, then something else must be causing this issue. When I get some more time, I will try to get to the bottom of it, but rest assured, there IS something amiss!

Another thing that I have noticed with the GPX to LDK import process is that the transparent area of custom icons are now displayed as white. This looks ugly compared with AQ v1.4.x, which handled icon transparency correctly. Is this something that can easily be fixed?

Note that I am trying hard to love AQ v2.x in the same way that I loved AQ v1.x, but it is proving to be a little more stressfull than I might have imagined. I do understand the reasoning for wanting to work with internal file formats, but the transition from GPX to LDK does not seem to be as smooth, nor as bullet proof as I would have expected, given the super high quality of your coding in the past. Hopefully things will improve as the usage issues get ironed out along the road... :)

Re: Landmark Open URL Function Missing !!!

Posted: Wed May 11, 2016 9:07 pm
by Psyberia-Support
Ok I'll double check every changes and try to reproduce.

I agree that the v2 is maybe not as "stable" as the 1.x, but it will get better with each updates...
I really think it was ready to be published (I've been testing it since last summer), I guess those few bugs come with the package of any major update...

Re: Landmark Open URL Function Missing !!!

Posted: Thu May 12, 2016 7:35 pm
by Yemble
I've amended my WW_Routes.gpx file to use relative URL paths, file://.\landmarks\GPX_Routes\ and this works a treat on the tablet and phones. Thanks again :-)

Unfortunately, however, I am still finding that the displayed (imported) GPX route files are still dead on the screen, on all devices. Have you managed to reproduce this?

The icon transparency issue does not appear to occur on the S3 phones, running CM13 (Marshmallow), but is still an issue on the tablet running CM12.1 (Lollipop). This is a bit odd, but may have nothing to do with AQ, so I'm not that bothered about it, unless you have any suggestions for a quick fix.

I also managed to get a repeatable Java error, from within Displayed Landmarks, by selecting (single tap) a previously imported GPX.LDK route file, then selecting the route within it (single tap). The error details are:

Call: onItemClick
Class: ayk
Throws: java.lang.NullPointerException
Message: Attempt to invoke interface method 'Boolean aqp2.cgn.y()' on a null object reference

Re: Landmark Open URL Function Missing !!!

Posted: Thu May 12, 2016 8:07 pm
by Yemble
Update. If I create a new route within AQ, then can edit the waypoints, etc., as expected. So the dead route issue is only affecting routes imported from GPX files. An example of the contents of one of these GPX route files follows...

<?xml version="1.0" encoding="UTF-8"?>
<gpx
version="1.1"
creator="GPSBabel - http://www.gpsbabel.org"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.topografix.com/GPX/1/1"
xsi:schemaLocation="http://www.topografix.com/GPX/1/1 http://www.topografix.com/GPX/1/1/gpx.xsd">
<metadata>
<time>2013-04-28T11:07:39Z</time>
<bounds minlat="51.562344121" minlon="-0.909029409" maxlat="51.607854293" maxlon="-0.867559168"/>
</metadata>
<rte>
<name>1</name>
<rtept lat="51.562344121" lon="-0.867559168">
<time>2006-01-12T13:30:19Z</time>
<name>1</name>
<cmt>01</cmt>
<desc>Turn right from the car park and left into the field at the T-junction. Walk north parallel to the road to the gate at the end of the field. Turn left onto the track and walk to the road. Turn right onto the road and walk a few metres up towards the cottage opposite.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.567811000" lon="-0.868085000">
<time>2006-01-12T13:30:21Z</time>
<name>2</name>
<cmt>02</cmt>
<desc>Turn left onto the track just past the cottage.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.566428692" lon="-0.871426230">
<time>2006-01-12T13:30:23Z</time>
<name>3</name>
<cmt>03</cmt>
<desc>On entering the woods you can take either path - they run in parallel.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.567031114" lon="-0.882668013">
<time>2006-01-12T13:30:25Z</time>
<name>4</name>
<cmt>04</cmt>
<desc>Turn right onto the track. Keep straight on.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.574898652" lon="-0.887165975">
<time>2006-01-12T13:30:27Z</time>
<name>5</name>
<cmt>05</cmt>
<desc>Continue straight on at this junction. The other tracks are marked Private. The person in this picture looks as though she`s going left...but she isn`t!</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.575870181" lon="-0.890029114">
<time>2006-01-12T13:30:33Z</time>
<name>05a</name>
<sym>Tiny dot</sym>
</rtept>
<rtept lat="51.581122224" lon="-0.889034829">
<time>2006-01-12T13:30:38Z</time>
<name>05b</name>
<sym>Tiny dot</sym>
</rtept>
<rtept lat="51.583022218" lon="-0.894979683">
<time>2006-01-12T13:30:58Z</time>
<name>6</name>
<cmt>06</cmt>
<desc>In the woods the path is marked clearly. Most alternative routes are marked Private. At this point take the path to the left up the side of the hill.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.587032000" lon="-0.903694000">
<time>2006-01-12T13:31:01Z</time>
<name>7</name>
<cmt>07</cmt>
<desc>When you leave the woods, follow the path with a hedge on the right hand side. Be very careful not to miss this stile on the right. If you reach the farm you have gone too far. Go straight across the field to the first gate. Then skirt the left hand side of the field to the stile in the corner.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.590601000" lon="-0.900721000">
<time>2006-01-12T13:31:03Z</time>
<name>8</name>
<cmt>08</cmt>
<desc>The path through the woods is well marked with white arrows on the trees. Keep going due North until you reach the road.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.594197000" lon="-0.900634000">
<time>2006-01-12T13:31:05Z</time>
<name>9</name>
<cmt>09</cmt>
<desc>Turn left onto the road. Follow the road out of the wood to reach a stile on your right.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.592582246" lon="-0.907382225">
<time>2002-06-25T10:13:25Z</time>
<name>10</name>
<cmt>10</cmt>
<desc>Cross the field to a stile leading into the woods. Follow the path down through the woods to a track crossing at right angles.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.596150229" lon="-0.909029409">
<time>2002-06-25T10:13:38Z</time>
<name>11</name>
<cmt>11</cmt>
<desc>Turn right onto the track.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.596794330" lon="-0.905764711">
<time>2002-06-25T10:13:43Z</time>
<name>12</name>
<cmt>12</cmt>
<desc>A short distance down the track don`t miss the small path on the right. If you reach a gate you have gone too far. Follow this path, which broadens out to a track, until you reach the road.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.598305699" lon="-0.899085218">
<time>2006-01-12T13:31:09Z</time>
<name>12a</name>
<sym>Tiny dot</sym>
</rtept>
<rtept lat="51.602506625" lon="-0.901077723">
<time>2006-01-12T13:31:14Z</time>
<name>12b</name>
<sym>Tiny dot</sym>
</rtept>
<rtept lat="51.606963938" lon="-0.896853343">
<time>2002-06-25T10:13:54Z</time>
<name>13</name>
<cmt>13</cmt>
<desc>Turn right onto the road and walk along it for about 100 metres.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.607854293" lon="-0.895892837">
<time>2002-07-04T13:04:52Z</time>
<name>14</name>
<cmt>14</cmt>
<desc>Turn off the road to the right through these gates. Follow the path through the woods and then directly across a small field.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.606792961" lon="-0.893029758">
<time>2002-07-04T13:04:46Z</time>
<name>15</name>
<cmt>15</cmt>
<desc>A very short way into the woods turn left onto a well defined path.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.607275013" lon="-0.886951356">
<time>2002-07-04T13:04:58Z</time>
<name>16</name>
<cmt>16</cmt>
<desc>Take the path down the side of this field to the road.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.606606000" lon="-0.881561000">
<time>2002-06-25T09:53:43Z</time>
<name>17</name>
<cmt>17</cmt>
<desc>Turn right onto the road and walk through the village of Skirmett. Pub on your right!</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.602973080" lon="-0.879112980">
<time>2002-07-04T13:05:03Z</time>
<name>18</name>
<cmt>18</cmt>
<desc>At the sharp right hand bend in the road, turn left. On your right cross the stile and cross the field. Cross a number of stiles as you make your way down the valley.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.592882682" lon="-0.874190575">
<time>2006-01-06T16:51:32Z</time>
<name>19</name>
<cmt>19</cmt>
<desc>The footpath sign at this point is slightly misleading. Do not turn right onto the road, cross straight over and continue along the footpath.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.586731000" lon="-0.871945000">
<time>2002-06-25T09:53:43Z</time>
<name>20</name>
<cmt>20</cmt>
<desc>Join the road for a short distance. Where it bends to the right, rejoin the footpath along the valley (through the small gate on the right in this picture).At Pheasant`s Hill the path passes between the gardens of a row of houses. Keep heading due south towards Hambleden Church.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.574132000" lon="-0.870814000">
<time>2002-06-25T09:53:43Z</time>
<name>21</name>
<cmt>21</cmt>
<desc>The path meets the road to the right of this picture. Turn left towards Hambleden. In the village centre turn right, walking past the shop.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.571317385" lon="-0.870078211">
<time>2002-07-04T13:05:27Z</time>
<name>22</name>
<cmt>22</cmt>
<desc>As you leave the village, take the path on the left immediately after the small bridge. Cross the field to rejoin the path back to the car park.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.567811000" lon="-0.868085000">
<time>2006-01-12T13:30:21Z</time>
<name>2</name>
<cmt>02</cmt>
<desc>Turn left onto the track just past the cottage.</desc>
<sym>Dot</sym>
</rtept>
<rtept lat="51.562344121" lon="-0.867559168">
<time>2006-01-12T13:30:19Z</time>
<name>1</name>
<cmt>01</cmt>
<desc>Turn right from the car park and left into the field at the T-junction. Walk north parallel to the road to the gate at the end of the field. Turn left onto the track and walk to the road. Turn right onto the road and walk a few metres up towards the cottage opposite.</desc>
<sym>Dot</sym>
</rtept>
</rte>
</gpx>

Re: Landmark Open URL Function Missing !!!

Posted: Thu May 12, 2016 8:40 pm
by Psyberia-Support
Thanks for the further details,
I've found the source of the error you've seen. I guess that the same problem that makes you unable to select the route from the map.
I'll make further test tonight and push a corrected version tomorrow in the beta channel (you should get it like a normal version since you're now registered as a beta tester).
Sorry for this problem :oops:

Until tomorrow, what you should be able to do after the import is to select "Browse", and display the route from there.

Re: Landmark Open URL Function Missing !!!

Posted: Fri May 13, 2016 11:19 am
by Yemble
Psyberia-Support wrote:Thanks for the further details,
I've found the source of the error you've seen. I guess that the same problem that makes you unable to select the route from the map.
I'll make further test tonight and push a corrected version tomorrow in the beta channel (you should get it like a normal version since you're now registered as a beta tester).
Sorry for this problem :oops:

Until tomorrow, what you should be able to do after the import is to select "Browse", and display the route from there.
Hey, no problem... this is what beta testing is all about, I had an inkling that the two issues might be related :ugeek:

Re: Landmark Open URL Function Missing !!!

Posted: Fri May 13, 2016 12:45 pm
by Yemble
Now that I have the landmarks with relative URLs working on my old, slow, S3 phone, I have been testing AQ 2.01 with some fairly large converted GPX files containing a lot of landmarks (eg. real ale pubs in the UK). Even in LDK format, these files seem to take rather longer to load on startup than the equivalent GPX files in AQ 1.4. This seems to be a little counter-intuitive to me as I thought one of the points of LDK format was to improve performance.

However, I think that this could be mitigated if the application opened quickly, displayed the map and then proceeded to load the displayed landmarks in background, whilst at the same time leaving the application functional (at least for basic operations). I think that this would be far preferable than having to staring at a white screen for a prolonged period, whilst waiting for the landmarks to load, before displaying the map.

Surely this would provide a better user experience for AQ on slow devices?

Would this be possible?

Re: Landmark Open URL Function Missing !!!

Posted: Fri May 13, 2016 4:45 pm
by Psyberia-Support
It's already the case when you display a complete ".ldk" file by itself (or a sub-folder a of .ldk file). That's the case when you import a GPX file and select "Display" after the import: the whole imported file is displayed. Unfortunately when doing that on-map selection is broken for routes as you've found (but it's working for all other types).
If you just display the items independently (ie if you see each of them independently in the "Displayed landmarks"), then the application will treat them as different items, and there is no gain (speaking about loading speed) compared to if they were saved on a common folder.

Re: Landmark Open URL Function Missing !!!

Posted: Sat May 14, 2016 6:21 am
by Yemble
So you are saying that the issue with GPX routes is also causing the slow load time. OK, I'll wait for the next beta and then re-test.