TinyGPS PLUS - Erratic cardinal directions

I’m getting erratic directions from TinyGPS. Am I missing something?
The course is bang on and stable too.

(gps.course.isValid() ? TinyGPSPlus::cardinal(gps.course.value()) : "*** ", 6);

Sats HDOP Latitude Longitude Fix Date Time Date Alt Course Speed Card Distance Course Card Chars Sentences Checksum
(deg) (deg) Age Age (m) from GPS to London RX RX Fail
10 79 42.934665 -81.187225 532 02/02/2015 23:37:14 659 270.50 75.06 88.21 NW 5877 50.48 NE 33813 1232 0
10 79 42.934722 -81.186935 565 02/02/2015 23:37:15 693 270.60 75.50 86.75 N 5877 50.48 NE 33871 1234 0
10 79 42.934780 -81.186645 595 02/02/2015 23:37:16 722 270.70 75.21 85.56 NW 5877 50.48 NE 33929 1236 0
10 79 42.934837 -81.186370 626 02/02/2015 23:37:17 754 270.80 74.72 84.25 W 5877 50.48 NE 33986 1238 0
10 79 42.934894 -81.186096 659 02/02/2015 23:37:18 787 271.00 74.07 82.88 SSW 5877 50.48 NE 34044 1240 0
10 79 42.934951 -81.185829 691 02/02/2015 23:37:19 818 271.20 73.91 79.69 S 5877 50.48 NE 34102 1242 0
10 79 42.935005 -81.185577 721 02/02/2015 23:37:20 848 271.30 73.77 75.25 S 5877 50.48 NE 34159 1244 0
10 79 42.935054 -81.185340 752 02/02/2015 23:37:21 879 271.50 73.69 71.52 S 5877 50.48 NE 34217 1246 0
10 79 42.935104 -81.185111 784 02/02/2015 23:37:22 911 271.70 73.79 67.99 S 5877 50.48 NE 34275 1248 0
10 79 42.935150 -81.184898 816 02/02/2015 23:37:23 943 271.90 74.13 64.56 SSW 5877 50.48 NE 34336 1250 0
10 79 42.935192 -81.184692 850 02/02/2015 23:37:24 977 272.10 75.36 62.75 NNW 5877 50.48 NE 34396 1252 0

What are the cardinal directions supposed to represent?

I would guess it should be showing direction of travel. It should be reading "E" or close to it on the part of highway I was recording on.

daves_nt_here: I'm getting erratic directions from TinyGPS. Am I missing something?

Is this the 100% original "FullExample.ino" sketch? Did you do some modifications?

Or did you even extend the code very much causing additional RAM usage?

Erratic behaviour may be caused when your sketch runs out of RAM and you try to use more RAM than the controller actually has built-in.

I've tried the TinyGPS "test_with_gps" & TinyGPS Plus "FullExample" as well as a couple of the other sample sketches in the TinyGPS Plus library. All with the same results. Tried on 3 different Uno's (one genuine) and a mega.

daves_nt_here: I've tried the TinyGPS "test_with_gps" & TinyGPS Plus "FullExample" as well as a couple of the other sample sketches in the TinyGPS Plus library. All with the same results.

OK, I've looked up some files and it seems that the malfunction occurs with some of your own changes that you did to the code.

I think the line you posted in your first posting should not be based on "gps.course.value()" but on "gps.course.deg()"

So most likely the processing code for "cardinal" should read like:

(gps.course.isValid() ? TinyGPSPlus::cardinal(gps.course.deg()) : "*** ", 6);

(untested)

Yup, that did it. I should have seen that.
But then why is it wrong in the example sketches. I use them as a fallback if I can’t figure them out. They should be polished and good to go right?

The angular directions seem to be quite consistent with the locations. It is the letter codes for those directions which look wrong.

daves_nt_here: But then why is it wrong in the example sketches.

I don't know. I did NOT write the example sketch(es).

The author of the TinyGPSPlus library perhaps - wants to give you a small hint about the quality of his library - wants you to think about the code yourself before using it in your projects - or maybe he is just awaiting for your bug-report to improve the example code in the next update

Who knows?

If the author should be waiting for bug reports, I ask myself why you are asking me about errors in that library and not Mikal Hart who wrote the library and example code.

So before no bug report reaches him, I've posted him the issue with his FullExample.ino sketch.

Perhaps nobody has yet informed him about that issue with the example code.