changes in dem-tdb branch

Hi all, slowly I seem to get closer to a solution for the crash problem. I've re-activated the dem-tdb branch to test some changes. With r4111 I've implemented a special option to force the problem case, so that the crash doesn't depend on the content of the hgt file or the dem-poly, see http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4111 When the extra flag is set, the crash is related to the position of the tile boundaries (TRE), the height and width - and therefore the overlaps - of the DEM area(s), the dem-dists values, the length of the route, the place where the route starts and ends, maybe more. I assume that MapSource makes certain assumptions about these values when the extra flag is set AND "something else" is true or false. This something might be a value in TRE or tdb, for example I've calculated a map for some tiles with the same (?) boundaries as in the Garmin map TopoGuide Hungary 2.12c. I've calculated some routes in the Garmin map and stored them in a *.gdb file. (no crashes with "Show profile..." button, data looks reasonable) I've used the same routes for the map calculated by mkgmap, I see crashes for some of them. I replaced the *.DEM data in the Garmin map by that from mkgmap and I see no crashes(!) (I made sure that I see the data calculated by mkgmap) It is difficult to create tiles with exactly the same boundary values in TRE and DEM and *.tdb, so maybe I still have to improve the code regarding rounding errors or calculation of the position. That's what I've done so far and I am still making progress... Another explanation is my conspiracy theory: It might be that MapSource is much more restrictive when the tdb file says that the map is not from Garmin, e.g. it is not lockable or whatever MapSource might use to detect that. Let's hope that this is not the case. BTW: Reg. "Show Profile.." /Graph I've learned that both MapSource and Basecamp use different DEM levels depending on the overall length of the route. With dem-dist=5520,16560,y the DEM level 0 (5520) is used for routes < ~ 29 km, 16560 is used for 29..86 km, y >= 87 With dem-dist=3312,x the DEM level 0 (3312) is used for routes < ~ 17,4 km The ratios show a constant value : 17,4 / 3312 ~ 29/5520 ~ 87 / 16560 ~ 190 The odd numbers are probably caused by different units (feet / metres). Gerd

Hi Gerd,
It might be that MapSource is much more restrictive when the tdb file says that the map is not from Garmin, e.g. it is not lockable or whatever MapSource might use to detect that.
This is the byte before "lowest map level", locked maps get value 1 there. I think you could use mkgmap to create a TDB for a Garmin's map. This could verify if TDB is relevant to the problem. I have already tested that TDB created by gmaptool doesn't solve crashes. -- Best regard, Andrzej

Hi Andrzej, thanks for the hints. Will try that as well. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Andrzej Popowski <popej@poczta.onet.pl> Gesendet: Montag, 12. Februar 2018 10:26:25 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] changes in dem-tdb branch Hi Gerd,
It might be that MapSource is much more restrictive when the tdb file says that the map is not from Garmin, e.g. it is not lockable or whatever MapSource might use to detect that.
This is the byte before "lowest map level", locked maps get value 1 there. I think you could use mkgmap to create a TDB for a Garmin's map. This could verify if TDB is relevant to the problem. I have already tested that TDB created by gmaptool doesn't solve crashes. -- Best regard, Andrzej _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Andrzej, seems that mkgmap has problems with the tiles in TopoGuide Hungary 2.12c. With JRE option -ea it fails, without it is very slow, probably because it tries to read wrong data :-( The display tool doesn't show these problems. Are you able to create a gmap folder for the tiles 00000025.img, 00000026.img, and 00000030.img ? If yes, what mkgmap version do you use and what options? Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen@hotmail.com> Gesendet: Montag, 12. Februar 2018 10:32:16 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] changes in dem-tdb branch Hi Andrzej, thanks for the hints. Will try that as well. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Andrzej Popowski <popej@poczta.onet.pl> Gesendet: Montag, 12. Februar 2018 10:26:25 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] changes in dem-tdb branch Hi Gerd,
It might be that MapSource is much more restrictive when the tdb file says that the map is not from Garmin, e.g. it is not lockable or whatever MapSource might use to detect that.
This is the byte before "lowest map level", locked maps get value 1 there. I think you could use mkgmap to create a TDB for a Garmin's map. This could verify if TDB is relevant to the problem. I have already tested that TDB created by gmaptool doesn't solve crashes. -- Best regard, Andrzej _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Gerd, I'm not sure, what are you asking about. Are you trying to create a TDB? I think this should work if you bypass creating of overview and mdr. If you only want to convert map to gmap format, then Garmin's MapConverter should work. -- Best regards, Andrzej

Hi Andrzej, I want to create a new tdb for these three files and use the new map in MapSource. I was able to create a *.tdb but MapSource doesn't display the map, only a light blue rectangle. I've also tried to modify the original Garmin files to reproduce the error, but without success. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces@lists.mkgmap.org.uk> im Auftrag von Andrzej Popowski <popej@poczta.onet.pl> Gesendet: Montag, 12. Februar 2018 19:52:26 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] changes in dem-tdb branch Hi Gerd, I'm not sure, what are you asking about. Are you trying to create a TDB? I think this should work if you bypass creating of overview and mdr. If you only want to convert map to gmap format, then Garmin's MapConverter should work. -- Best regards, Andrzej _______________________________________________ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Hi Gerd, TDB doesn't need much info. There is a function FileInfo.getFileInfo(), which seems to provide all what is needed. You probably would have to comment parts of code, which deals with overview map and mdr index, but it is too difficult for me to find these parts in all sources. So I'm not able to make my own tests. If you can create a new TDB, then you should simply swap TDB in original map. I can't guess, if you follow the same idea or what have you done exactly. Could you upload TDB, that you have created? -- Best regards, Andrzej
participants (3)
-
Andrzej Popowski
-
Gerd Petermann
-
Gerd Petermann