SPI - Fix Transfer16 plus allow subclass to gain access to member var… #18
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.
resolves #13
And: provides for c) option in #14
In particular, added another config option (config16) that is initialized at beginTransaction with same settings as config except word size set to 16 instead of 8.
Also: updated begin() to call beginTransaction with default SPISettings, and the endTransaction, such that sketches that don't call beginTransaction output at the default settings.
Changed the header file private: to protected
Notes: I noticed that you had merged #6, so I redownloaded the main branch, reapplied my SPI changes, did the bootstrap.sh followed by the build.sh and then retried two sketches.
The main applicable one here is:
Note this uses my own display library for the ILI9341 display
Output from this is:
Two parts here:
a) It shows that the transfer16 is working to do an update screen...
Also shows a quick and dirty sub-class of SPI.
Unfortunately, you probably can not use it in a normal way, where you create an object of it... As the SPI objects
are already created.
So I cast a pointer to the SPI object to be of this class, and then verified I could get the correct information.
Shown getting it two different ways: