[PATCH v1] adjust turn headings more

This patch modifies the turn heading adjustment code so that the GPS will tell you to turn when you are routing from a main road to a side road in situations like this: S S ^ S | MMMMMMMMMMMMMM | M | M | M M You can see that the main road goes around a left corner and the side road carries straight on. Without this patch, neither mapsource or a Nuvi will tell you to turn right at this junction even if the side road has a different road class/speed from the main road. This patch also allows you to globally enable/disable the possible adjustments by providing a bitmask with the --adjust-turn-headings option. By default, all (currently, there are 2) kinds of adjustments are enabled. See the help blurb for more info. A value of 1 gives the old behaviour. Mark

Mark Burton wrote:
This patch modifies the turn heading adjustment code so that the GPS will tell you to turn when you are routing from a main road to a side road in situations like this:
S S ^ S | MMMMMMMMMMMMMM | M | M | M M
You can see that the main road goes around a left corner and the side road carries straight on. Without this patch, neither mapsource or a Nuvi will tell you to turn right at this junction even if the side road has a different road class/speed from the main road.
This patch also allows you to globally enable/disable the possible adjustments by providing a bitmask with the --adjust-turn-headings option. By default, all (currently, there are 2) kinds of adjustments are enabled. See the help blurb for more info.
A value of 1 gives the old behaviour.
Mark
Cool. I'd noticed that my GPS wasn't coping with this situation properly before. Are there any further turn behaviours that still need to be coded for? Charlie

Hello Charlie,
Cool. I'd noticed that my GPS wasn't coping with this situation properly before.
Please give it a go and see if makes things better (or worse).
Are there any further turn behaviours that still need to be coded for?
Yes, I can think of two other behaviours that could be handled better: 1 - when travelling from a side road to a main road, if the angle at which the side road joins the main road becomes shallow, you don't get a turn instruction. This isn't always a problem but sometimes it's not that obvious to the human whether they should turn left or right without looking at the gps display. 2 - this is more annoying, when reaching a fork in the road where neither of the roads are a continuation of the current road, you don't always get an instruction (when the heading of the one of the exit roads is a close match to the incoming road's heading). I have tried coding for both of the scenarios but, so far, have had no success at improving the GPS's directions. Cheers, Mark

On 22/01/2010 13:14, Mark Burton wrote:
This patch modifies the turn heading adjustment code so that the GPS will tell you to turn when you are routing from a main road to a side road in situations like this:
S S ^ S | MMMMMMMMMMMMMM | M | M | M M
You can see that the main road goes around a left corner and the side road carries straight on. Without this patch, neither mapsource or a Nuvi will tell you to turn right at this junction even if the side road has a different road class/speed from the main road.
This patch also allows you to globally enable/disable the possible adjustments by providing a bitmask with the --adjust-turn-headings option. By default, all (currently, there are 2) kinds of adjustments are enabled. See the help blurb for more info.
A value of 1 gives the old behaviour.
Mark
The patch seems to work fine, insofar as it doesn't make anything break, but I can't seem to find any candidate junctions where the effect of the patch is obvious. Charlie

Hello Charlie,
The patch seems to work fine, insofar as it doesn't make anything break, but I can't seem to find any candidate junctions where the effect of the patch is obvious.
OK - thanks for the report. Anyone else tried this? If so, was it good/bad/the same/didn't notice/don't care/what's for tea? Mark

On Jan 25, 2010, at 16:36, Mark Burton wrote:
Anyone else tried this? If so, was it good/bad/the same/didn't notice/don't care/what's for tea?
I've been testing a map compiled with this patch for the past couple of days. Since I don't have a good test case, I was not able to notice any large differences. It seemed to me that the Nuvi was a bit more talkative than usual, but that could be my imagination. The patch appears to be at least mostly harmless. ;-) Cheers.

Hi Clinton,
I've been testing a map compiled with this patch for the past couple of days. Since I don't have a good test case, I was not able to notice any large differences. It seemed to me that the Nuvi was a bit more talkative than usual, but that could be my imagination.
The patch appears to be at least mostly harmless. ;-)
Thanks for the report. I have 3 junctions near where I live that now produce directions when they didn't before so I am reasonably confident that it's working OK and, so far, no negative reports have arrived so I shall probably commit it soon. Mark
participants (3)
-
Charlie Ferrero
-
Clinton Gladstone
-
Mark Burton