botletics / Botletics-SIM7000

Arduino library repo for the Botletics SIM7000 Shield
https://www.botletics.com/products/sim7000-shield
GNU General Public License v3.0
19 stars 9 forks source link

Specify version of FONA this is meant to extend #4

Closed nabeel-halo closed 1 year ago

nabeel-halo commented 1 year ago

I see this library is still in development but I was excited to give it a try. I installed it to Arduino IDE and also installed latest FONA (1.3.11), but it results in a ton of mismatching overload definitions between the two libraries. I also tried other versions of FONA but was unable to find a version that worked.

Sample compilation errors (there are many):

/home/nabeel/Arduino/libraries/Botletics-SIM7000-main/src/BotleticsSIM7000.cpp:3665:9: error: prototype for 'boolean Adafruit_FONA::sendCheckReply(const char*, FONAFlashStringPtr, uint16_t)' does not match any in class 'Adafruit_FONA'
 boolean Adafruit_FONA::sendCheckReply(const char* send, FONAFlashStringPtr reply, uint16_t timeout) {
         ^~~~~~~~~~~~~

This being I assume because that overload doesn't exist for sendCheckReply and a new overload (or any definition) cannot occur outside of the class definition.

How can I properly compile this library?

botletics commented 1 year ago

Sorry for the confusion! This library was just ported over to meet the Arduino library manager guidelines. Release 1.0.0 actually had a compile error, but you should be able to find and install 1.0.1 with the Arduino library manager soon.

botletics commented 1 year ago

Release 1.0.3 fixes the compiler errors. Please check now!

nabeel-halo commented 1 year ago

Thank you! I can confirm it compiles and runs perfectly. Please also consider uploading this library to the PlatformIO Library Registry. They fully support Arduino libraries (the library.json spec is recommended, but library.properties is accepted), so there would be no changes needed. PlatformIO is a widely used "more serious" alternative to the Arduino IDE! Thanks again!