I feel like they shouldn't be, as spelling kind of seems like it should be exact. But I cannot find the GPS++ version. Using the GPSPlusPlus results in
"fatal error: TinyGPSPlusPlus.h: No such file or directory"
message. But since the code will not accept any GPS library I put in it I'm not sure. I've tried using TinyGPSPlus but get the same results.
New to this, last time I did programming on the regular I used Basic on a Texas Instruments. So it's probably a simple 'turn this on' that I'm missing. The Auto Format seemed to remove other issues but this one is persistant.
This is the error message after it verifies.
FQBN: arduino:avr:nano
Using board 'nano' from platform in folder: C:\Users\matthew green\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.8
Using core 'arduino' from platform in folder: C:\Users\matthew green\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.8
This sketch, which I did not write originally, called for library TinyGPS++. I've seen this exact library called out in other sketches. When I search for TinyGPS++ the main result that comes back is TinyGPSPlus or TinyGPSPlusPlus. I've tried modifying it (the code) to include GPS libraries that I have and cannot get any of them to work.
It is important to understand the distinction between a library and a header file.
A library is a collection of reusable code.
A header file contains code that is intended to be exposed to other source code files via #include directives.
Libraries contain one or more header files. However, header files are also present in software components other than libraries.
It is common for a library to contain a primary header file with a name matching the library name. This may cause you to assume that an #include directive for a given header file is referencing a library of that same name. However, the developer is free to name their header files however they choose, so there is no guarantee of a match between the name of the primary header file and the library name.
Furthermore, the library may contain multiple header files, so even in the case where the primary header file does exactly match the library name, you may still find #include directives for header files with names that do not match the library.
Effective communication is very important. If you are trying to communicate about a problem relating to a header file, then you should write "header file". If you write "library" when you are actually referring to a header file, then that may cause confusion and wasted time.
TinyGPS++ and TinyGPSPlusPlus are referring to the same library. The actual library is called TinyGPS++, but the header file is usually TinyGPS++.h , not TinyGPSPlusPlus.h .
If you're getting:
fatal error: TinyGPSPlusPlus.h: No such file or directory
then the code is likely using the wrong include statement. Try changing it to:
#include <TinyGPS++.h>
Also make sure the TinyGPS++ library is installed through the Arduino Library Manager. A lot of examples online use slightly different naming conventions, which can be confusing when you're starting out.
If you post the include lines and the exact error message, someone can probably spot the issue pretty quickly.
When referring to a library, we must use the library name. This is how the library will be identified by Arduino development tools, for example:
In the Arduino IDE Library Manager
In the output from the sketch build process
In command line invocations
The library maintainer defines the name of their library via the name property in the library's metadata file. If we look at the metadata file, we will see the following:
name=TinyGPSPlusPlus
So this library's name is "TinyGPSPlusPlus", not "TinyGPS++".
Referring to a library by anything other than its canonical name is incorrect and will lead to miscommunication, confusion, and wasted time.
The name of the header file provided by the "TinyGPSPlusPlus" library is TinyGPSPlus.h.
Although the primary focus of @mtgreen's post was apparently the "TinyGPSPlusPlus" library, the other more popular and trusted "TinyGPSPlus" library was also mentioned in this discussion. It is true the "TinyGPSPlus" library contains a header file named TinyGPS++.h: