Repo improvements: PlatformIO library setup, improved .gitignore and .gitattributes, GitHub license detection #138
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Folder restructuring for PlatformIO and Arduino IDE
This PR simplifies the folder structure so that PlatformIO and Arduino IDE can include it. It also adds the metadata files (
library.json
for PlatformIO andlibrary.properties
for Arduino IDE).Arduino expects all source and header files in the same directory called
src
.PlatformIO is an IDE for embedded development that makes it easy to build and maintain Arduino projects.
By creating a
library.json
definition, it is possible to create a library that is easy to use in PlatformIO.Conditional code inclusion
To prevent Arduino and PlatformIO automatically picking up cpp files for unused interfaces (like
SoftwareSerial
for SWHSU), compile flags are introduced. This also prevents compiler errors where SoftwareSerial is not available like on ESP32.Git metadata files
A generated
.gitignore
file is added based on thec++
andPlatformIO
technologies using https://gitignore.io/..gitattributes
is added to prevent issues with cross-platform line endings.Metadata
The metadata files automatically take a dependency on Don's NDEF library, so that it is not needed to maintain a copy in this repo.
License detection
This PR also moves the license file so that GitHub can recognize it.
Code fixes
This PR includes fixes from #126, #129 and #133. For simplicity I reapplied the code-changes rather than cross-merging branches, but I want to attribute @FStefanni, @JEphron and @redstonee here.