Hi Mark,
The default style-file of course should have something like below:
highway=*& (surface=unpaved | surface=dirt | surface=sand |
surface=ground | surface=gravel | tracktype=grade2 | tracktype=grade3 | tracktype=grade4 | tracktype=grade5 | sac_scale=* | smothness= ........) {add unpaved=yes}
Felix echoes my thoughts exactly. There's lot's of surface values that
imply unpavedness so using surface=unpaved isn't the way to go. I did
wonder about using a mkgmap specific tag, e.g. mkgmap:unpaved=yes but
as unpaved=yes (or paved=no) do not obviously conflict with existing OSM
tags, I thought I would not use the mkgmap: prefix.
http://wiki.openstreetmap.org/wiki/Proposed_features/surface_unification
suggests surface:material, but then again, surface:material=asphalt,
surface:condition!=maintained can be worse than some surface:material=gravel.
It seems best to introduce a mkgmap:paved tag that can be translated
into by style files.
If people are happy with that, I will commit the patch soon as it is.
For what it is worth, I tried your v2 patch with the following, but I was
unable to convince my Edge 705 to suggest using a forest path that it
used to suggest until some weeks ago. (In other words, it avoided the
unpaved roads no matter what the routing preference was.)
-- It makes not much sense to test like you do. You should build a
testmap in JOSM and then do the testing to check whether it works or
not. If a road is added as paved=no, then it will not be choosen at all
even if it is much much shorter if you block it. Just like toll=yes.
This is different to blocking something with motorcar=no, here it will
block less strictly (only blocks as via, no blocking as terminal road).