Closed hallgchris closed 4 years ago
No worries, thanks for the PR :) I'll check that ASAP. I made some changes on the API I have yet to commit, I'll see to merge first I guess, and update everything afterwards.
I don't really use CMake that much, but it usually works, so no issues there. Did you check that there are no conflicts with Arduino?
Everything seems to work fine code-wise. The only issue I've noticed is how the Arduino IDE handles the examples now that I've made Arduino and Raspberry Pi specific subfolders.
I think this would be resolved if I moved everything in examples/arduino
back to its original location in examples
, but then the folder structure would be a bit messier. How would you prefer I had the folders?
Other than this, the library still seems to work great in my testing on a Teensy 3.6.
I guess the best way would be to create a dedicated example folder for the RPi, like examples_raspberrypi
, at root level. Arduino should only look in the src
and examples
folders for source files and examples, if I remember correctly. Give it a try?
I'll merge this WE and push all my updates too.
Of course, that's so much cleaner! I've moved the examples to the locations you suggested.
Thank you for your PR, I merged it. I also added my updates and had to fix your files a bit, so a test would be nice to make sure everything's still good ;) Note that I renamed ZetaRF to ZetaRf (lowercase f), because I love changing everything. maybe. :P
No worries! Very happy to contribute :)
There's a few issues I've found:
CMakeLists.txt
needs updating.
src/ZetaRF.cpp
-> src/ZetaRf.cpp
.h
needs changing to .hpp
but I now realise that adding the header as a source isn't required at all, so "src/configs/*.h"
may be removed entirelyZetaRf.hpp
, the hasDataAvailble()
typo was not fixedreadVariableLengthPacketTo
has been changed and needs updating in both the RPi and Arduino examplesSeems to be all good other than those few things!
That should be all fixed now, thank you! :)
No problem! Working great now :)
Hey, sorry this took a little while! Thought I should have a go using the library before I made the PR to check it's actually usable.
I'm using the CMake build system, mainly because it's the only thing I really no how to use. Do you have any thoughts on this? Any suggestions on how I could do this better, considering this is primarily an Arduino IDE project?
If you have an RPi lying around, you should be able to compile it with
cmake .
thenmake
.Happy to make whatever changes/improvements you can think of, so let me know and I'll try my best :)
(Fixes #11)